fast-path.generated.go 731 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626462746284629463046314632463346344635463646374638463946404641464246434644464546464647464846494650465146524653465446554656465746584659466046614662466346644665466646674668466946704671467246734674467546764677467846794680468146824683468446854686468746884689469046914692469346944695469646974698469947004701470247034704470547064707470847094710471147124713471447154716471747184719472047214722472347244725472647274728472947304731473247334734473547364737473847394740474147424743474447454746474747484749475047514752475347544755475647574758475947604761476247634764476547664767476847694770477147724773477447754776477747784779478047814782478347844785478647874788478947904791479247934794479547964797479847994800480148024803480448054806480748084809481048114812481348144815481648174818481948204821482248234824482548264827482848294830483148324833483448354836483748384839484048414842484348444845484648474848484948504851485248534854485548564857485848594860486148624863486448654866486748684869487048714872487348744875487648774878487948804881488248834884488548864887488848894890489148924893489448954896489748984899490049014902490349044905490649074908490949104911491249134914491549164917491849194920492149224923492449254926492749284929493049314932493349344935493649374938493949404941494249434944494549464947494849494950495149524953495449554956495749584959496049614962496349644965496649674968496949704971497249734974497549764977497849794980498149824983498449854986498749884989499049914992499349944995499649974998499950005001500250035004500550065007500850095010501150125013501450155016501750185019502050215022502350245025502650275028502950305031503250335034503550365037503850395040504150425043504450455046504750485049505050515052505350545055505650575058505950605061506250635064506550665067506850695070507150725073507450755076507750785079508050815082508350845085508650875088508950905091509250935094509550965097509850995100510151025103510451055106510751085109511051115112511351145115511651175118511951205121512251235124512551265127512851295130513151325133513451355136513751385139514051415142514351445145514651475148514951505151515251535154515551565157515851595160516151625163516451655166516751685169517051715172517351745175517651775178517951805181518251835184518551865187518851895190519151925193519451955196519751985199520052015202520352045205520652075208520952105211521252135214521552165217521852195220522152225223522452255226522752285229523052315232523352345235523652375238523952405241524252435244524552465247524852495250525152525253525452555256525752585259526052615262526352645265526652675268526952705271527252735274527552765277527852795280528152825283528452855286528752885289529052915292529352945295529652975298529953005301530253035304530553065307530853095310531153125313531453155316531753185319532053215322532353245325532653275328532953305331533253335334533553365337533853395340534153425343534453455346534753485349535053515352535353545355535653575358535953605361536253635364536553665367536853695370537153725373537453755376537753785379538053815382538353845385538653875388538953905391539253935394539553965397539853995400540154025403540454055406540754085409541054115412541354145415541654175418541954205421542254235424542554265427542854295430543154325433543454355436543754385439544054415442544354445445544654475448544954505451545254535454545554565457545854595460546154625463546454655466546754685469547054715472547354745475547654775478547954805481548254835484548554865487548854895490549154925493549454955496549754985499550055015502550355045505550655075508550955105511551255135514551555165517551855195520552155225523552455255526552755285529553055315532553355345535553655375538553955405541554255435544554555465547554855495550555155525553555455555556555755585559556055615562556355645565556655675568556955705571557255735574557555765577557855795580558155825583558455855586558755885589559055915592559355945595559655975598559956005601560256035604560556065607560856095610561156125613561456155616561756185619562056215622562356245625562656275628562956305631563256335634563556365637563856395640564156425643564456455646564756485649565056515652565356545655565656575658565956605661566256635664566556665667566856695670567156725673567456755676567756785679568056815682568356845685568656875688568956905691569256935694569556965697569856995700570157025703570457055706570757085709571057115712571357145715571657175718571957205721572257235724572557265727572857295730573157325733573457355736573757385739574057415742574357445745574657475748574957505751575257535754575557565757575857595760576157625763576457655766576757685769577057715772577357745775577657775778577957805781578257835784578557865787578857895790579157925793579457955796579757985799580058015802580358045805580658075808580958105811581258135814581558165817581858195820582158225823582458255826582758285829583058315832583358345835583658375838583958405841584258435844584558465847584858495850585158525853585458555856585758585859586058615862586358645865586658675868586958705871587258735874587558765877587858795880588158825883588458855886588758885889589058915892589358945895589658975898589959005901590259035904590559065907590859095910591159125913591459155916591759185919592059215922592359245925592659275928592959305931593259335934593559365937593859395940594159425943594459455946594759485949595059515952595359545955595659575958595959605961596259635964596559665967596859695970597159725973597459755976597759785979598059815982598359845985598659875988598959905991599259935994599559965997599859996000600160026003600460056006600760086009601060116012601360146015601660176018601960206021602260236024602560266027602860296030603160326033603460356036603760386039604060416042604360446045604660476048604960506051605260536054605560566057605860596060606160626063606460656066606760686069607060716072607360746075607660776078607960806081608260836084608560866087608860896090609160926093609460956096609760986099610061016102610361046105610661076108610961106111611261136114611561166117611861196120612161226123612461256126612761286129613061316132613361346135613661376138613961406141614261436144614561466147614861496150615161526153615461556156615761586159616061616162616361646165616661676168616961706171617261736174617561766177617861796180618161826183618461856186618761886189619061916192619361946195619661976198619962006201620262036204620562066207620862096210621162126213621462156216621762186219622062216222622362246225622662276228622962306231623262336234623562366237623862396240624162426243624462456246624762486249625062516252625362546255625662576258625962606261626262636264626562666267626862696270627162726273627462756276627762786279628062816282628362846285628662876288628962906291629262936294629562966297629862996300630163026303630463056306630763086309631063116312631363146315631663176318631963206321632263236324632563266327632863296330633163326333633463356336633763386339634063416342634363446345634663476348634963506351635263536354635563566357635863596360636163626363636463656366636763686369637063716372637363746375637663776378637963806381638263836384638563866387638863896390639163926393639463956396639763986399640064016402640364046405640664076408640964106411641264136414641564166417641864196420642164226423642464256426642764286429643064316432643364346435643664376438643964406441644264436444644564466447644864496450645164526453645464556456645764586459646064616462646364646465646664676468646964706471647264736474647564766477647864796480648164826483648464856486648764886489649064916492649364946495649664976498649965006501650265036504650565066507650865096510651165126513651465156516651765186519652065216522652365246525652665276528652965306531653265336534653565366537653865396540654165426543654465456546654765486549655065516552655365546555655665576558655965606561656265636564656565666567656865696570657165726573657465756576657765786579658065816582658365846585658665876588658965906591659265936594659565966597659865996600660166026603660466056606660766086609661066116612661366146615661666176618661966206621662266236624662566266627662866296630663166326633663466356636663766386639664066416642664366446645664666476648664966506651665266536654665566566657665866596660666166626663666466656666666766686669667066716672667366746675667666776678667966806681668266836684668566866687668866896690669166926693669466956696669766986699670067016702670367046705670667076708670967106711671267136714671567166717671867196720672167226723672467256726672767286729673067316732673367346735673667376738673967406741674267436744674567466747674867496750675167526753675467556756675767586759676067616762676367646765676667676768676967706771677267736774677567766777677867796780678167826783678467856786678767886789679067916792679367946795679667976798679968006801680268036804680568066807680868096810681168126813681468156816681768186819682068216822682368246825682668276828682968306831683268336834683568366837683868396840684168426843684468456846684768486849685068516852685368546855685668576858685968606861686268636864686568666867686868696870687168726873687468756876687768786879688068816882688368846885688668876888688968906891689268936894689568966897689868996900690169026903690469056906690769086909691069116912691369146915691669176918691969206921692269236924692569266927692869296930693169326933693469356936693769386939694069416942694369446945694669476948694969506951695269536954695569566957695869596960696169626963696469656966696769686969697069716972697369746975697669776978697969806981698269836984698569866987698869896990699169926993699469956996699769986999700070017002700370047005700670077008700970107011701270137014701570167017701870197020702170227023702470257026702770287029703070317032703370347035703670377038703970407041704270437044704570467047704870497050705170527053705470557056705770587059706070617062706370647065706670677068706970707071707270737074707570767077707870797080708170827083708470857086708770887089709070917092709370947095709670977098709971007101710271037104710571067107710871097110711171127113711471157116711771187119712071217122712371247125712671277128712971307131713271337134713571367137713871397140714171427143714471457146714771487149715071517152715371547155715671577158715971607161716271637164716571667167716871697170717171727173717471757176717771787179718071817182718371847185718671877188718971907191719271937194719571967197719871997200720172027203720472057206720772087209721072117212721372147215721672177218721972207221722272237224722572267227722872297230723172327233723472357236723772387239724072417242724372447245724672477248724972507251725272537254725572567257725872597260726172627263726472657266726772687269727072717272727372747275727672777278727972807281728272837284728572867287728872897290729172927293729472957296729772987299730073017302730373047305730673077308730973107311731273137314731573167317731873197320732173227323732473257326732773287329733073317332733373347335733673377338733973407341734273437344734573467347734873497350735173527353735473557356735773587359736073617362736373647365736673677368736973707371737273737374737573767377737873797380738173827383738473857386738773887389739073917392739373947395739673977398739974007401740274037404740574067407740874097410741174127413741474157416741774187419742074217422742374247425742674277428742974307431743274337434743574367437743874397440744174427443744474457446744774487449745074517452745374547455745674577458745974607461746274637464746574667467746874697470747174727473747474757476747774787479748074817482748374847485748674877488748974907491749274937494749574967497749874997500750175027503750475057506750775087509751075117512751375147515751675177518751975207521752275237524752575267527752875297530753175327533753475357536753775387539754075417542754375447545754675477548754975507551755275537554755575567557755875597560756175627563756475657566756775687569757075717572757375747575757675777578757975807581758275837584758575867587758875897590759175927593759475957596759775987599760076017602760376047605760676077608760976107611761276137614761576167617761876197620762176227623762476257626762776287629763076317632763376347635763676377638763976407641764276437644764576467647764876497650765176527653765476557656765776587659766076617662766376647665766676677668766976707671767276737674767576767677767876797680768176827683768476857686768776887689769076917692769376947695769676977698769977007701770277037704770577067707770877097710771177127713771477157716771777187719772077217722772377247725772677277728772977307731773277337734773577367737773877397740774177427743774477457746774777487749775077517752775377547755775677577758775977607761776277637764776577667767776877697770777177727773777477757776777777787779778077817782778377847785778677877788778977907791779277937794779577967797779877997800780178027803780478057806780778087809781078117812781378147815781678177818781978207821782278237824782578267827782878297830783178327833783478357836783778387839784078417842784378447845784678477848784978507851785278537854785578567857785878597860786178627863786478657866786778687869787078717872787378747875787678777878787978807881788278837884788578867887788878897890789178927893789478957896789778987899790079017902790379047905790679077908790979107911791279137914791579167917791879197920792179227923792479257926792779287929793079317932793379347935793679377938793979407941794279437944794579467947794879497950795179527953795479557956795779587959796079617962796379647965796679677968796979707971797279737974797579767977797879797980798179827983798479857986798779887989799079917992799379947995799679977998799980008001800280038004800580068007800880098010801180128013801480158016801780188019802080218022802380248025802680278028802980308031803280338034803580368037803880398040804180428043804480458046804780488049805080518052805380548055805680578058805980608061806280638064806580668067806880698070807180728073807480758076807780788079808080818082808380848085808680878088808980908091809280938094809580968097809880998100810181028103810481058106810781088109811081118112811381148115811681178118811981208121812281238124812581268127812881298130813181328133813481358136813781388139814081418142814381448145814681478148814981508151815281538154815581568157815881598160816181628163816481658166816781688169817081718172817381748175817681778178817981808181818281838184818581868187818881898190819181928193819481958196819781988199820082018202820382048205820682078208820982108211821282138214821582168217821882198220822182228223822482258226822782288229823082318232823382348235823682378238823982408241824282438244824582468247824882498250825182528253825482558256825782588259826082618262826382648265826682678268826982708271827282738274827582768277827882798280828182828283828482858286828782888289829082918292829382948295829682978298829983008301830283038304830583068307830883098310831183128313831483158316831783188319832083218322832383248325832683278328832983308331833283338334833583368337833883398340834183428343834483458346834783488349835083518352835383548355835683578358835983608361836283638364836583668367836883698370837183728373837483758376837783788379838083818382838383848385838683878388838983908391839283938394839583968397839883998400840184028403840484058406840784088409841084118412841384148415841684178418841984208421842284238424842584268427842884298430843184328433843484358436843784388439844084418442844384448445844684478448844984508451845284538454845584568457845884598460846184628463846484658466846784688469847084718472847384748475847684778478847984808481848284838484848584868487848884898490849184928493849484958496849784988499850085018502850385048505850685078508850985108511851285138514851585168517851885198520852185228523852485258526852785288529853085318532853385348535853685378538853985408541854285438544854585468547854885498550855185528553855485558556855785588559856085618562856385648565856685678568856985708571857285738574857585768577857885798580858185828583858485858586858785888589859085918592859385948595859685978598859986008601860286038604860586068607860886098610861186128613861486158616861786188619862086218622862386248625862686278628862986308631863286338634863586368637863886398640864186428643864486458646864786488649865086518652865386548655865686578658865986608661866286638664866586668667866886698670867186728673867486758676867786788679868086818682868386848685868686878688868986908691869286938694869586968697869886998700870187028703870487058706870787088709871087118712871387148715871687178718871987208721872287238724872587268727872887298730873187328733873487358736873787388739874087418742874387448745874687478748874987508751875287538754875587568757875887598760876187628763876487658766876787688769877087718772877387748775877687778778877987808781878287838784878587868787878887898790879187928793879487958796879787988799880088018802880388048805880688078808880988108811881288138814881588168817881888198820882188228823882488258826882788288829883088318832883388348835883688378838883988408841884288438844884588468847884888498850885188528853885488558856885788588859886088618862886388648865886688678868886988708871887288738874887588768877887888798880888188828883888488858886888788888889889088918892889388948895889688978898889989008901890289038904890589068907890889098910891189128913891489158916891789188919892089218922892389248925892689278928892989308931893289338934893589368937893889398940894189428943894489458946894789488949895089518952895389548955895689578958895989608961896289638964896589668967896889698970897189728973897489758976897789788979898089818982898389848985898689878988898989908991899289938994899589968997899889999000900190029003900490059006900790089009901090119012901390149015901690179018901990209021902290239024902590269027902890299030903190329033903490359036903790389039904090419042904390449045904690479048904990509051905290539054905590569057905890599060906190629063906490659066906790689069907090719072907390749075907690779078907990809081908290839084908590869087908890899090909190929093909490959096909790989099910091019102910391049105910691079108910991109111911291139114911591169117911891199120912191229123912491259126912791289129913091319132913391349135913691379138913991409141914291439144914591469147914891499150915191529153915491559156915791589159916091619162916391649165916691679168916991709171917291739174917591769177917891799180918191829183918491859186918791889189919091919192919391949195919691979198919992009201920292039204920592069207920892099210921192129213921492159216921792189219922092219222922392249225922692279228922992309231923292339234923592369237923892399240924192429243924492459246924792489249925092519252925392549255925692579258925992609261926292639264926592669267926892699270927192729273927492759276927792789279928092819282928392849285928692879288928992909291929292939294929592969297929892999300930193029303930493059306930793089309931093119312931393149315931693179318931993209321932293239324932593269327932893299330933193329333933493359336933793389339934093419342934393449345934693479348934993509351935293539354935593569357935893599360936193629363936493659366936793689369937093719372937393749375937693779378937993809381938293839384938593869387938893899390939193929393939493959396939793989399940094019402940394049405940694079408940994109411941294139414941594169417941894199420942194229423942494259426942794289429943094319432943394349435943694379438943994409441944294439444944594469447944894499450945194529453945494559456945794589459946094619462946394649465946694679468946994709471947294739474947594769477947894799480948194829483948494859486948794889489949094919492949394949495949694979498949995009501950295039504950595069507950895099510951195129513951495159516951795189519952095219522952395249525952695279528952995309531953295339534953595369537953895399540954195429543954495459546954795489549955095519552955395549555955695579558955995609561956295639564956595669567956895699570957195729573957495759576957795789579958095819582958395849585958695879588958995909591959295939594959595969597959895999600960196029603960496059606960796089609961096119612961396149615961696179618961996209621962296239624962596269627962896299630963196329633963496359636963796389639964096419642964396449645964696479648964996509651965296539654965596569657965896599660966196629663966496659666966796689669967096719672967396749675967696779678967996809681968296839684968596869687968896899690969196929693969496959696969796989699970097019702970397049705970697079708970997109711971297139714971597169717971897199720972197229723972497259726972797289729973097319732973397349735973697379738973997409741974297439744974597469747974897499750975197529753975497559756975797589759976097619762976397649765976697679768976997709771977297739774977597769777977897799780978197829783978497859786978797889789979097919792979397949795979697979798979998009801980298039804980598069807980898099810981198129813981498159816981798189819982098219822982398249825982698279828982998309831983298339834983598369837983898399840984198429843984498459846984798489849985098519852985398549855985698579858985998609861986298639864986598669867986898699870987198729873987498759876987798789879988098819882988398849885988698879888988998909891989298939894989598969897989898999900990199029903990499059906990799089909991099119912991399149915991699179918991999209921992299239924992599269927992899299930993199329933993499359936993799389939994099419942994399449945994699479948994999509951995299539954995599569957995899599960996199629963996499659966996799689969997099719972997399749975997699779978997999809981998299839984998599869987998899899990999199929993999499959996999799989999100001000110002100031000410005100061000710008100091001010011100121001310014100151001610017100181001910020100211002210023100241002510026100271002810029100301003110032100331003410035100361003710038100391004010041100421004310044100451004610047100481004910050100511005210053100541005510056100571005810059100601006110062100631006410065100661006710068100691007010071100721007310074100751007610077100781007910080100811008210083100841008510086100871008810089100901009110092100931009410095100961009710098100991010010101101021010310104101051010610107101081010910110101111011210113101141011510116101171011810119101201012110122101231012410125101261012710128101291013010131101321013310134101351013610137101381013910140101411014210143101441014510146101471014810149101501015110152101531015410155101561015710158101591016010161101621016310164101651016610167101681016910170101711017210173101741017510176101771017810179101801018110182101831018410185101861018710188101891019010191101921019310194101951019610197101981019910200102011020210203102041020510206102071020810209102101021110212102131021410215102161021710218102191022010221102221022310224102251022610227102281022910230102311023210233102341023510236102371023810239102401024110242102431024410245102461024710248102491025010251102521025310254102551025610257102581025910260102611026210263102641026510266102671026810269102701027110272102731027410275102761027710278102791028010281102821028310284102851028610287102881028910290102911029210293102941029510296102971029810299103001030110302103031030410305103061030710308103091031010311103121031310314103151031610317103181031910320103211032210323103241032510326103271032810329103301033110332103331033410335103361033710338103391034010341103421034310344103451034610347103481034910350103511035210353103541035510356103571035810359103601036110362103631036410365103661036710368103691037010371103721037310374103751037610377103781037910380103811038210383103841038510386103871038810389103901039110392103931039410395103961039710398103991040010401104021040310404104051040610407104081040910410104111041210413104141041510416104171041810419104201042110422104231042410425104261042710428104291043010431104321043310434104351043610437104381043910440104411044210443104441044510446104471044810449104501045110452104531045410455104561045710458104591046010461104621046310464104651046610467104681046910470104711047210473104741047510476104771047810479104801048110482104831048410485104861048710488104891049010491104921049310494104951049610497104981049910500105011050210503105041050510506105071050810509105101051110512105131051410515105161051710518105191052010521105221052310524105251052610527105281052910530105311053210533105341053510536105371053810539105401054110542105431054410545105461054710548105491055010551105521055310554105551055610557105581055910560105611056210563105641056510566105671056810569105701057110572105731057410575105761057710578105791058010581105821058310584105851058610587105881058910590105911059210593105941059510596105971059810599106001060110602106031060410605106061060710608106091061010611106121061310614106151061610617106181061910620106211062210623106241062510626106271062810629106301063110632106331063410635106361063710638106391064010641106421064310644106451064610647106481064910650106511065210653106541065510656106571065810659106601066110662106631066410665106661066710668106691067010671106721067310674106751067610677106781067910680106811068210683106841068510686106871068810689106901069110692106931069410695106961069710698106991070010701107021070310704107051070610707107081070910710107111071210713107141071510716107171071810719107201072110722107231072410725107261072710728107291073010731107321073310734107351073610737107381073910740107411074210743107441074510746107471074810749107501075110752107531075410755107561075710758107591076010761107621076310764107651076610767107681076910770107711077210773107741077510776107771077810779107801078110782107831078410785107861078710788107891079010791107921079310794107951079610797107981079910800108011080210803108041080510806108071080810809108101081110812108131081410815108161081710818108191082010821108221082310824108251082610827108281082910830108311083210833108341083510836108371083810839108401084110842108431084410845108461084710848108491085010851108521085310854108551085610857108581085910860108611086210863108641086510866108671086810869108701087110872108731087410875108761087710878108791088010881108821088310884108851088610887108881088910890108911089210893108941089510896108971089810899109001090110902109031090410905109061090710908109091091010911109121091310914109151091610917109181091910920109211092210923109241092510926109271092810929109301093110932109331093410935109361093710938109391094010941109421094310944109451094610947109481094910950109511095210953109541095510956109571095810959109601096110962109631096410965109661096710968109691097010971109721097310974109751097610977109781097910980109811098210983109841098510986109871098810989109901099110992109931099410995109961099710998109991100011001110021100311004110051100611007110081100911010110111101211013110141101511016110171101811019110201102111022110231102411025110261102711028110291103011031110321103311034110351103611037110381103911040110411104211043110441104511046110471104811049110501105111052110531105411055110561105711058110591106011061110621106311064110651106611067110681106911070110711107211073110741107511076110771107811079110801108111082110831108411085110861108711088110891109011091110921109311094110951109611097110981109911100111011110211103111041110511106111071110811109111101111111112111131111411115111161111711118111191112011121111221112311124111251112611127111281112911130111311113211133111341113511136111371113811139111401114111142111431114411145111461114711148111491115011151111521115311154111551115611157111581115911160111611116211163111641116511166111671116811169111701117111172111731117411175111761117711178111791118011181111821118311184111851118611187111881118911190111911119211193111941119511196111971119811199112001120111202112031120411205112061120711208112091121011211112121121311214112151121611217112181121911220112211122211223112241122511226112271122811229112301123111232112331123411235112361123711238112391124011241112421124311244112451124611247112481124911250112511125211253112541125511256112571125811259112601126111262112631126411265112661126711268112691127011271112721127311274112751127611277112781127911280112811128211283112841128511286112871128811289112901129111292112931129411295112961129711298112991130011301113021130311304113051130611307113081130911310113111131211313113141131511316113171131811319113201132111322113231132411325113261132711328113291133011331113321133311334113351133611337113381133911340113411134211343113441134511346113471134811349113501135111352113531135411355113561135711358113591136011361113621136311364113651136611367113681136911370113711137211373113741137511376113771137811379113801138111382113831138411385113861138711388113891139011391113921139311394113951139611397113981139911400114011140211403114041140511406114071140811409114101141111412114131141411415114161141711418114191142011421114221142311424114251142611427114281142911430114311143211433114341143511436114371143811439114401144111442114431144411445114461144711448114491145011451114521145311454114551145611457114581145911460114611146211463114641146511466114671146811469114701147111472114731147411475114761147711478114791148011481114821148311484114851148611487114881148911490114911149211493114941149511496114971149811499115001150111502115031150411505115061150711508115091151011511115121151311514115151151611517115181151911520115211152211523115241152511526115271152811529115301153111532115331153411535115361153711538115391154011541115421154311544115451154611547115481154911550115511155211553115541155511556115571155811559115601156111562115631156411565115661156711568115691157011571115721157311574115751157611577115781157911580115811158211583115841158511586115871158811589115901159111592115931159411595115961159711598115991160011601116021160311604116051160611607116081160911610116111161211613116141161511616116171161811619116201162111622116231162411625116261162711628116291163011631116321163311634116351163611637116381163911640116411164211643116441164511646116471164811649116501165111652116531165411655116561165711658116591166011661116621166311664116651166611667116681166911670116711167211673116741167511676116771167811679116801168111682116831168411685116861168711688116891169011691116921169311694116951169611697116981169911700117011170211703117041170511706117071170811709117101171111712117131171411715117161171711718117191172011721117221172311724117251172611727117281172911730117311173211733117341173511736117371173811739117401174111742117431174411745117461174711748117491175011751117521175311754117551175611757117581175911760117611176211763117641176511766117671176811769117701177111772117731177411775117761177711778117791178011781117821178311784117851178611787117881178911790117911179211793117941179511796117971179811799118001180111802118031180411805118061180711808118091181011811118121181311814118151181611817118181181911820118211182211823118241182511826118271182811829118301183111832118331183411835118361183711838118391184011841118421184311844118451184611847118481184911850118511185211853118541185511856118571185811859118601186111862118631186411865118661186711868118691187011871118721187311874118751187611877118781187911880118811188211883118841188511886118871188811889118901189111892118931189411895118961189711898118991190011901119021190311904119051190611907119081190911910119111191211913119141191511916119171191811919119201192111922119231192411925119261192711928119291193011931119321193311934119351193611937119381193911940119411194211943119441194511946119471194811949119501195111952119531195411955119561195711958119591196011961119621196311964119651196611967119681196911970119711197211973119741197511976119771197811979119801198111982119831198411985119861198711988119891199011991119921199311994119951199611997119981199912000120011200212003120041200512006120071200812009120101201112012120131201412015120161201712018120191202012021120221202312024120251202612027120281202912030120311203212033120341203512036120371203812039120401204112042120431204412045120461204712048120491205012051120521205312054120551205612057120581205912060120611206212063120641206512066120671206812069120701207112072120731207412075120761207712078120791208012081120821208312084120851208612087120881208912090120911209212093120941209512096120971209812099121001210112102121031210412105121061210712108121091211012111121121211312114121151211612117121181211912120121211212212123121241212512126121271212812129121301213112132121331213412135121361213712138121391214012141121421214312144121451214612147121481214912150121511215212153121541215512156121571215812159121601216112162121631216412165121661216712168121691217012171121721217312174121751217612177121781217912180121811218212183121841218512186121871218812189121901219112192121931219412195121961219712198121991220012201122021220312204122051220612207122081220912210122111221212213122141221512216122171221812219122201222112222122231222412225122261222712228122291223012231122321223312234122351223612237122381223912240122411224212243122441224512246122471224812249122501225112252122531225412255122561225712258122591226012261122621226312264122651226612267122681226912270122711227212273122741227512276122771227812279122801228112282122831228412285122861228712288122891229012291122921229312294122951229612297122981229912300123011230212303123041230512306123071230812309123101231112312123131231412315123161231712318123191232012321123221232312324123251232612327123281232912330123311233212333123341233512336123371233812339123401234112342123431234412345123461234712348123491235012351123521235312354123551235612357123581235912360123611236212363123641236512366123671236812369123701237112372123731237412375123761237712378123791238012381123821238312384123851238612387123881238912390123911239212393123941239512396123971239812399124001240112402124031240412405124061240712408124091241012411124121241312414124151241612417124181241912420124211242212423124241242512426124271242812429124301243112432124331243412435124361243712438124391244012441124421244312444124451244612447124481244912450124511245212453124541245512456124571245812459124601246112462124631246412465124661246712468124691247012471124721247312474124751247612477124781247912480124811248212483124841248512486124871248812489124901249112492124931249412495124961249712498124991250012501125021250312504125051250612507125081250912510125111251212513125141251512516125171251812519125201252112522125231252412525125261252712528125291253012531125321253312534125351253612537125381253912540125411254212543125441254512546125471254812549125501255112552125531255412555125561255712558125591256012561125621256312564125651256612567125681256912570125711257212573125741257512576125771257812579125801258112582125831258412585125861258712588125891259012591125921259312594125951259612597125981259912600126011260212603126041260512606126071260812609126101261112612126131261412615126161261712618126191262012621126221262312624126251262612627126281262912630126311263212633126341263512636126371263812639126401264112642126431264412645126461264712648126491265012651126521265312654126551265612657126581265912660126611266212663126641266512666126671266812669126701267112672126731267412675126761267712678126791268012681126821268312684126851268612687126881268912690126911269212693126941269512696126971269812699127001270112702127031270412705127061270712708127091271012711127121271312714127151271612717127181271912720127211272212723127241272512726127271272812729127301273112732127331273412735127361273712738127391274012741127421274312744127451274612747127481274912750127511275212753127541275512756127571275812759127601276112762127631276412765127661276712768127691277012771127721277312774127751277612777127781277912780127811278212783127841278512786127871278812789127901279112792127931279412795127961279712798127991280012801128021280312804128051280612807128081280912810128111281212813128141281512816128171281812819128201282112822128231282412825128261282712828128291283012831128321283312834128351283612837128381283912840128411284212843128441284512846128471284812849128501285112852128531285412855128561285712858128591286012861128621286312864128651286612867128681286912870128711287212873128741287512876128771287812879128801288112882128831288412885128861288712888128891289012891128921289312894128951289612897128981289912900129011290212903129041290512906129071290812909129101291112912129131291412915129161291712918129191292012921129221292312924129251292612927129281292912930129311293212933129341293512936129371293812939129401294112942129431294412945129461294712948129491295012951129521295312954129551295612957129581295912960129611296212963129641296512966129671296812969129701297112972129731297412975129761297712978129791298012981129821298312984129851298612987129881298912990129911299212993129941299512996129971299812999130001300113002130031300413005130061300713008130091301013011130121301313014130151301613017130181301913020130211302213023130241302513026130271302813029130301303113032130331303413035130361303713038130391304013041130421304313044130451304613047130481304913050130511305213053130541305513056130571305813059130601306113062130631306413065130661306713068130691307013071130721307313074130751307613077130781307913080130811308213083130841308513086130871308813089130901309113092130931309413095130961309713098130991310013101131021310313104131051310613107131081310913110131111311213113131141311513116131171311813119131201312113122131231312413125131261312713128131291313013131131321313313134131351313613137131381313913140131411314213143131441314513146131471314813149131501315113152131531315413155131561315713158131591316013161131621316313164131651316613167131681316913170131711317213173131741317513176131771317813179131801318113182131831318413185131861318713188131891319013191131921319313194131951319613197131981319913200132011320213203132041320513206132071320813209132101321113212132131321413215132161321713218132191322013221132221322313224132251322613227132281322913230132311323213233132341323513236132371323813239132401324113242132431324413245132461324713248132491325013251132521325313254132551325613257132581325913260132611326213263132641326513266132671326813269132701327113272132731327413275132761327713278132791328013281132821328313284132851328613287132881328913290132911329213293132941329513296132971329813299133001330113302133031330413305133061330713308133091331013311133121331313314133151331613317133181331913320133211332213323133241332513326133271332813329133301333113332133331333413335133361333713338133391334013341133421334313344133451334613347133481334913350133511335213353133541335513356133571335813359133601336113362133631336413365133661336713368133691337013371133721337313374133751337613377133781337913380133811338213383133841338513386133871338813389133901339113392133931339413395133961339713398133991340013401134021340313404134051340613407134081340913410134111341213413134141341513416134171341813419134201342113422134231342413425134261342713428134291343013431134321343313434134351343613437134381343913440134411344213443134441344513446134471344813449134501345113452134531345413455134561345713458134591346013461134621346313464134651346613467134681346913470134711347213473134741347513476134771347813479134801348113482134831348413485134861348713488134891349013491134921349313494134951349613497134981349913500135011350213503135041350513506135071350813509135101351113512135131351413515135161351713518135191352013521135221352313524135251352613527135281352913530135311353213533135341353513536135371353813539135401354113542135431354413545135461354713548135491355013551135521355313554135551355613557135581355913560135611356213563135641356513566135671356813569135701357113572135731357413575135761357713578135791358013581135821358313584135851358613587135881358913590135911359213593135941359513596135971359813599136001360113602136031360413605136061360713608136091361013611136121361313614136151361613617136181361913620136211362213623136241362513626136271362813629136301363113632136331363413635136361363713638136391364013641136421364313644136451364613647136481364913650136511365213653136541365513656136571365813659136601366113662136631366413665136661366713668136691367013671136721367313674136751367613677136781367913680136811368213683136841368513686136871368813689136901369113692136931369413695136961369713698136991370013701137021370313704137051370613707137081370913710137111371213713137141371513716137171371813719137201372113722137231372413725137261372713728137291373013731137321373313734137351373613737137381373913740137411374213743137441374513746137471374813749137501375113752137531375413755137561375713758137591376013761137621376313764137651376613767137681376913770137711377213773137741377513776137771377813779137801378113782137831378413785137861378713788137891379013791137921379313794137951379613797137981379913800138011380213803138041380513806138071380813809138101381113812138131381413815138161381713818138191382013821138221382313824138251382613827138281382913830138311383213833138341383513836138371383813839138401384113842138431384413845138461384713848138491385013851138521385313854138551385613857138581385913860138611386213863138641386513866138671386813869138701387113872138731387413875138761387713878138791388013881138821388313884138851388613887138881388913890138911389213893138941389513896138971389813899139001390113902139031390413905139061390713908139091391013911139121391313914139151391613917139181391913920139211392213923139241392513926139271392813929139301393113932139331393413935139361393713938139391394013941139421394313944139451394613947139481394913950139511395213953139541395513956139571395813959139601396113962139631396413965139661396713968139691397013971139721397313974139751397613977139781397913980139811398213983139841398513986139871398813989139901399113992139931399413995139961399713998139991400014001140021400314004140051400614007140081400914010140111401214013140141401514016140171401814019140201402114022140231402414025140261402714028140291403014031140321403314034140351403614037140381403914040140411404214043140441404514046140471404814049140501405114052140531405414055140561405714058140591406014061140621406314064140651406614067140681406914070140711407214073140741407514076140771407814079140801408114082140831408414085140861408714088140891409014091140921409314094140951409614097140981409914100141011410214103141041410514106141071410814109141101411114112141131411414115141161411714118141191412014121141221412314124141251412614127141281412914130141311413214133141341413514136141371413814139141401414114142141431414414145141461414714148141491415014151141521415314154141551415614157141581415914160141611416214163141641416514166141671416814169141701417114172141731417414175141761417714178141791418014181141821418314184141851418614187141881418914190141911419214193141941419514196141971419814199142001420114202142031420414205142061420714208142091421014211142121421314214142151421614217142181421914220142211422214223142241422514226142271422814229142301423114232142331423414235142361423714238142391424014241142421424314244142451424614247142481424914250142511425214253142541425514256142571425814259142601426114262142631426414265142661426714268142691427014271142721427314274142751427614277142781427914280142811428214283142841428514286142871428814289142901429114292142931429414295142961429714298142991430014301143021430314304143051430614307143081430914310143111431214313143141431514316143171431814319143201432114322143231432414325143261432714328143291433014331143321433314334143351433614337143381433914340143411434214343143441434514346143471434814349143501435114352143531435414355143561435714358143591436014361143621436314364143651436614367143681436914370143711437214373143741437514376143771437814379143801438114382143831438414385143861438714388143891439014391143921439314394143951439614397143981439914400144011440214403144041440514406144071440814409144101441114412144131441414415144161441714418144191442014421144221442314424144251442614427144281442914430144311443214433144341443514436144371443814439144401444114442144431444414445144461444714448144491445014451144521445314454144551445614457144581445914460144611446214463144641446514466144671446814469144701447114472144731447414475144761447714478144791448014481144821448314484144851448614487144881448914490144911449214493144941449514496144971449814499145001450114502145031450414505145061450714508145091451014511145121451314514145151451614517145181451914520145211452214523145241452514526145271452814529145301453114532145331453414535145361453714538145391454014541145421454314544145451454614547145481454914550145511455214553145541455514556145571455814559145601456114562145631456414565145661456714568145691457014571145721457314574145751457614577145781457914580145811458214583145841458514586145871458814589145901459114592145931459414595145961459714598145991460014601146021460314604146051460614607146081460914610146111461214613146141461514616146171461814619146201462114622146231462414625146261462714628146291463014631146321463314634146351463614637146381463914640146411464214643146441464514646146471464814649146501465114652146531465414655146561465714658146591466014661146621466314664146651466614667146681466914670146711467214673146741467514676146771467814679146801468114682146831468414685146861468714688146891469014691146921469314694146951469614697146981469914700147011470214703147041470514706147071470814709147101471114712147131471414715147161471714718147191472014721147221472314724147251472614727147281472914730147311473214733147341473514736147371473814739147401474114742147431474414745147461474714748147491475014751147521475314754147551475614757147581475914760147611476214763147641476514766147671476814769147701477114772147731477414775147761477714778147791478014781147821478314784147851478614787147881478914790147911479214793147941479514796147971479814799148001480114802148031480414805148061480714808148091481014811148121481314814148151481614817148181481914820148211482214823148241482514826148271482814829148301483114832148331483414835148361483714838148391484014841148421484314844148451484614847148481484914850148511485214853148541485514856148571485814859148601486114862148631486414865148661486714868148691487014871148721487314874148751487614877148781487914880148811488214883148841488514886148871488814889148901489114892148931489414895148961489714898148991490014901149021490314904149051490614907149081490914910149111491214913149141491514916149171491814919149201492114922149231492414925149261492714928149291493014931149321493314934149351493614937149381493914940149411494214943149441494514946149471494814949149501495114952149531495414955149561495714958149591496014961149621496314964149651496614967149681496914970149711497214973149741497514976149771497814979149801498114982149831498414985149861498714988149891499014991149921499314994149951499614997149981499915000150011500215003150041500515006150071500815009150101501115012150131501415015150161501715018150191502015021150221502315024150251502615027150281502915030150311503215033150341503515036150371503815039150401504115042150431504415045150461504715048150491505015051150521505315054150551505615057150581505915060150611506215063150641506515066150671506815069150701507115072150731507415075150761507715078150791508015081150821508315084150851508615087150881508915090150911509215093150941509515096150971509815099151001510115102151031510415105151061510715108151091511015111151121511315114151151511615117151181511915120151211512215123151241512515126151271512815129151301513115132151331513415135151361513715138151391514015141151421514315144151451514615147151481514915150151511515215153151541515515156151571515815159151601516115162151631516415165151661516715168151691517015171151721517315174151751517615177151781517915180151811518215183151841518515186151871518815189151901519115192151931519415195151961519715198151991520015201152021520315204152051520615207152081520915210152111521215213152141521515216152171521815219152201522115222152231522415225152261522715228152291523015231152321523315234152351523615237152381523915240152411524215243152441524515246152471524815249152501525115252152531525415255152561525715258152591526015261152621526315264152651526615267152681526915270152711527215273152741527515276152771527815279152801528115282152831528415285152861528715288152891529015291152921529315294152951529615297152981529915300153011530215303153041530515306153071530815309153101531115312153131531415315153161531715318153191532015321153221532315324153251532615327153281532915330153311533215333153341533515336153371533815339153401534115342153431534415345153461534715348153491535015351153521535315354153551535615357153581535915360153611536215363153641536515366153671536815369153701537115372153731537415375153761537715378153791538015381153821538315384153851538615387153881538915390153911539215393153941539515396153971539815399154001540115402154031540415405154061540715408154091541015411154121541315414154151541615417154181541915420154211542215423154241542515426154271542815429154301543115432154331543415435154361543715438154391544015441154421544315444154451544615447154481544915450154511545215453154541545515456154571545815459154601546115462154631546415465154661546715468154691547015471154721547315474154751547615477154781547915480154811548215483154841548515486154871548815489154901549115492154931549415495154961549715498154991550015501155021550315504155051550615507155081550915510155111551215513155141551515516155171551815519155201552115522155231552415525155261552715528155291553015531155321553315534155351553615537155381553915540155411554215543155441554515546155471554815549155501555115552155531555415555155561555715558155591556015561155621556315564155651556615567155681556915570155711557215573155741557515576155771557815579155801558115582155831558415585155861558715588155891559015591155921559315594155951559615597155981559915600156011560215603156041560515606156071560815609156101561115612156131561415615156161561715618156191562015621156221562315624156251562615627156281562915630156311563215633156341563515636156371563815639156401564115642156431564415645156461564715648156491565015651156521565315654156551565615657156581565915660156611566215663156641566515666156671566815669156701567115672156731567415675156761567715678156791568015681156821568315684156851568615687156881568915690156911569215693156941569515696156971569815699157001570115702157031570415705157061570715708157091571015711157121571315714157151571615717157181571915720157211572215723157241572515726157271572815729157301573115732157331573415735157361573715738157391574015741157421574315744157451574615747157481574915750157511575215753157541575515756157571575815759157601576115762157631576415765157661576715768157691577015771157721577315774157751577615777157781577915780157811578215783157841578515786157871578815789157901579115792157931579415795157961579715798157991580015801158021580315804158051580615807158081580915810158111581215813158141581515816158171581815819158201582115822158231582415825158261582715828158291583015831158321583315834158351583615837158381583915840158411584215843158441584515846158471584815849158501585115852158531585415855158561585715858158591586015861158621586315864158651586615867158681586915870158711587215873158741587515876158771587815879158801588115882158831588415885158861588715888158891589015891158921589315894158951589615897158981589915900159011590215903159041590515906159071590815909159101591115912159131591415915159161591715918159191592015921159221592315924159251592615927159281592915930159311593215933159341593515936159371593815939159401594115942159431594415945159461594715948159491595015951159521595315954159551595615957159581595915960159611596215963159641596515966159671596815969159701597115972159731597415975159761597715978159791598015981159821598315984159851598615987159881598915990159911599215993159941599515996159971599815999160001600116002160031600416005160061600716008160091601016011160121601316014160151601616017160181601916020160211602216023160241602516026160271602816029160301603116032160331603416035160361603716038160391604016041160421604316044160451604616047160481604916050160511605216053160541605516056160571605816059160601606116062160631606416065160661606716068160691607016071160721607316074160751607616077160781607916080160811608216083160841608516086160871608816089160901609116092160931609416095160961609716098160991610016101161021610316104161051610616107161081610916110161111611216113161141611516116161171611816119161201612116122161231612416125161261612716128161291613016131161321613316134161351613616137161381613916140161411614216143161441614516146161471614816149161501615116152161531615416155161561615716158161591616016161161621616316164161651616616167161681616916170161711617216173161741617516176161771617816179161801618116182161831618416185161861618716188161891619016191161921619316194161951619616197161981619916200162011620216203162041620516206162071620816209162101621116212162131621416215162161621716218162191622016221162221622316224162251622616227162281622916230162311623216233162341623516236162371623816239162401624116242162431624416245162461624716248162491625016251162521625316254162551625616257162581625916260162611626216263162641626516266162671626816269162701627116272162731627416275162761627716278162791628016281162821628316284162851628616287162881628916290162911629216293162941629516296162971629816299163001630116302163031630416305163061630716308163091631016311163121631316314163151631616317163181631916320163211632216323163241632516326163271632816329163301633116332163331633416335163361633716338163391634016341163421634316344163451634616347163481634916350163511635216353163541635516356163571635816359163601636116362163631636416365163661636716368163691637016371163721637316374163751637616377163781637916380163811638216383163841638516386163871638816389163901639116392163931639416395163961639716398163991640016401164021640316404164051640616407164081640916410164111641216413164141641516416164171641816419164201642116422164231642416425164261642716428164291643016431164321643316434164351643616437164381643916440164411644216443164441644516446164471644816449164501645116452164531645416455164561645716458164591646016461164621646316464164651646616467164681646916470164711647216473164741647516476164771647816479164801648116482164831648416485164861648716488164891649016491164921649316494164951649616497164981649916500165011650216503165041650516506165071650816509165101651116512165131651416515165161651716518165191652016521165221652316524165251652616527165281652916530165311653216533165341653516536165371653816539165401654116542165431654416545165461654716548165491655016551165521655316554165551655616557165581655916560165611656216563165641656516566165671656816569165701657116572165731657416575165761657716578165791658016581165821658316584165851658616587165881658916590165911659216593165941659516596165971659816599166001660116602166031660416605166061660716608166091661016611166121661316614166151661616617166181661916620166211662216623166241662516626166271662816629166301663116632166331663416635166361663716638166391664016641166421664316644166451664616647166481664916650166511665216653166541665516656166571665816659166601666116662166631666416665166661666716668166691667016671166721667316674166751667616677166781667916680166811668216683166841668516686166871668816689166901669116692166931669416695166961669716698166991670016701167021670316704167051670616707167081670916710167111671216713167141671516716167171671816719167201672116722167231672416725167261672716728167291673016731167321673316734167351673616737167381673916740167411674216743167441674516746167471674816749167501675116752167531675416755167561675716758167591676016761167621676316764167651676616767167681676916770167711677216773167741677516776167771677816779167801678116782167831678416785167861678716788167891679016791167921679316794167951679616797167981679916800168011680216803168041680516806168071680816809168101681116812168131681416815168161681716818168191682016821168221682316824168251682616827168281682916830168311683216833168341683516836168371683816839168401684116842168431684416845168461684716848168491685016851168521685316854168551685616857168581685916860168611686216863168641686516866168671686816869168701687116872168731687416875168761687716878168791688016881168821688316884168851688616887168881688916890168911689216893168941689516896168971689816899169001690116902169031690416905169061690716908169091691016911169121691316914169151691616917169181691916920169211692216923169241692516926169271692816929169301693116932169331693416935169361693716938169391694016941169421694316944169451694616947169481694916950169511695216953169541695516956169571695816959169601696116962169631696416965169661696716968169691697016971169721697316974169751697616977169781697916980169811698216983169841698516986169871698816989169901699116992169931699416995169961699716998169991700017001170021700317004170051700617007170081700917010170111701217013170141701517016170171701817019170201702117022170231702417025170261702717028170291703017031170321703317034170351703617037170381703917040170411704217043170441704517046170471704817049170501705117052170531705417055170561705717058170591706017061170621706317064170651706617067170681706917070170711707217073170741707517076170771707817079170801708117082170831708417085170861708717088170891709017091170921709317094170951709617097170981709917100171011710217103171041710517106171071710817109171101711117112171131711417115171161711717118171191712017121171221712317124171251712617127171281712917130171311713217133171341713517136171371713817139171401714117142171431714417145171461714717148171491715017151171521715317154171551715617157171581715917160171611716217163171641716517166171671716817169171701717117172171731717417175171761717717178171791718017181171821718317184171851718617187171881718917190171911719217193171941719517196171971719817199172001720117202172031720417205172061720717208172091721017211172121721317214172151721617217172181721917220172211722217223172241722517226172271722817229172301723117232172331723417235172361723717238172391724017241172421724317244172451724617247172481724917250172511725217253172541725517256172571725817259172601726117262172631726417265172661726717268172691727017271172721727317274172751727617277172781727917280172811728217283172841728517286172871728817289172901729117292172931729417295172961729717298172991730017301173021730317304173051730617307173081730917310173111731217313173141731517316173171731817319173201732117322173231732417325173261732717328173291733017331173321733317334173351733617337173381733917340173411734217343173441734517346173471734817349173501735117352173531735417355173561735717358173591736017361173621736317364173651736617367173681736917370173711737217373173741737517376173771737817379173801738117382173831738417385173861738717388173891739017391173921739317394173951739617397173981739917400174011740217403174041740517406174071740817409174101741117412174131741417415174161741717418174191742017421174221742317424174251742617427174281742917430174311743217433174341743517436174371743817439174401744117442174431744417445174461744717448174491745017451174521745317454174551745617457174581745917460174611746217463174641746517466174671746817469174701747117472174731747417475174761747717478174791748017481174821748317484174851748617487174881748917490174911749217493174941749517496174971749817499175001750117502175031750417505175061750717508175091751017511175121751317514175151751617517175181751917520175211752217523175241752517526175271752817529175301753117532175331753417535175361753717538175391754017541175421754317544175451754617547175481754917550175511755217553175541755517556175571755817559175601756117562175631756417565175661756717568175691757017571175721757317574175751757617577175781757917580175811758217583175841758517586175871758817589175901759117592175931759417595175961759717598175991760017601176021760317604176051760617607176081760917610176111761217613176141761517616176171761817619176201762117622176231762417625176261762717628176291763017631176321763317634176351763617637176381763917640176411764217643176441764517646176471764817649176501765117652176531765417655176561765717658176591766017661176621766317664176651766617667176681766917670176711767217673176741767517676176771767817679176801768117682176831768417685176861768717688176891769017691176921769317694176951769617697176981769917700177011770217703177041770517706177071770817709177101771117712177131771417715177161771717718177191772017721177221772317724177251772617727177281772917730177311773217733177341773517736177371773817739177401774117742177431774417745177461774717748177491775017751177521775317754177551775617757177581775917760177611776217763177641776517766177671776817769177701777117772177731777417775177761777717778177791778017781177821778317784177851778617787177881778917790177911779217793177941779517796177971779817799178001780117802178031780417805178061780717808178091781017811178121781317814178151781617817178181781917820178211782217823178241782517826178271782817829178301783117832178331783417835178361783717838178391784017841178421784317844178451784617847178481784917850178511785217853178541785517856178571785817859178601786117862178631786417865178661786717868178691787017871178721787317874178751787617877178781787917880178811788217883178841788517886178871788817889178901789117892178931789417895178961789717898178991790017901179021790317904179051790617907179081790917910179111791217913179141791517916179171791817919179201792117922179231792417925179261792717928179291793017931179321793317934179351793617937179381793917940179411794217943179441794517946179471794817949179501795117952179531795417955179561795717958179591796017961179621796317964179651796617967179681796917970179711797217973179741797517976179771797817979179801798117982179831798417985179861798717988179891799017991179921799317994179951799617997179981799918000180011800218003180041800518006180071800818009180101801118012180131801418015180161801718018180191802018021180221802318024180251802618027180281802918030180311803218033180341803518036180371803818039180401804118042180431804418045180461804718048180491805018051180521805318054180551805618057180581805918060180611806218063180641806518066180671806818069180701807118072180731807418075180761807718078180791808018081180821808318084180851808618087180881808918090180911809218093180941809518096180971809818099181001810118102181031810418105181061810718108181091811018111181121811318114181151811618117181181811918120181211812218123181241812518126181271812818129181301813118132181331813418135181361813718138181391814018141181421814318144181451814618147181481814918150181511815218153181541815518156181571815818159181601816118162181631816418165181661816718168181691817018171181721817318174181751817618177181781817918180181811818218183181841818518186181871818818189181901819118192181931819418195181961819718198181991820018201182021820318204182051820618207182081820918210182111821218213182141821518216182171821818219182201822118222182231822418225182261822718228182291823018231182321823318234182351823618237182381823918240182411824218243182441824518246182471824818249182501825118252182531825418255182561825718258182591826018261182621826318264182651826618267182681826918270182711827218273182741827518276182771827818279182801828118282182831828418285182861828718288182891829018291182921829318294182951829618297182981829918300183011830218303183041830518306183071830818309183101831118312183131831418315183161831718318183191832018321183221832318324183251832618327183281832918330183311833218333183341833518336183371833818339183401834118342183431834418345183461834718348183491835018351183521835318354183551835618357183581835918360183611836218363183641836518366183671836818369183701837118372183731837418375183761837718378183791838018381183821838318384183851838618387183881838918390183911839218393183941839518396183971839818399184001840118402184031840418405184061840718408184091841018411184121841318414184151841618417184181841918420184211842218423184241842518426184271842818429184301843118432184331843418435184361843718438184391844018441184421844318444184451844618447184481844918450184511845218453184541845518456184571845818459184601846118462184631846418465184661846718468184691847018471184721847318474184751847618477184781847918480184811848218483184841848518486184871848818489184901849118492184931849418495184961849718498184991850018501185021850318504185051850618507185081850918510185111851218513185141851518516185171851818519185201852118522185231852418525185261852718528185291853018531185321853318534185351853618537185381853918540185411854218543185441854518546185471854818549185501855118552185531855418555185561855718558185591856018561185621856318564185651856618567185681856918570185711857218573185741857518576185771857818579185801858118582185831858418585185861858718588185891859018591185921859318594185951859618597185981859918600186011860218603186041860518606186071860818609186101861118612186131861418615186161861718618186191862018621186221862318624186251862618627186281862918630186311863218633186341863518636186371863818639186401864118642186431864418645186461864718648186491865018651186521865318654186551865618657186581865918660186611866218663186641866518666186671866818669186701867118672186731867418675186761867718678186791868018681186821868318684186851868618687186881868918690186911869218693186941869518696186971869818699187001870118702187031870418705187061870718708187091871018711187121871318714187151871618717187181871918720187211872218723187241872518726187271872818729187301873118732187331873418735187361873718738187391874018741187421874318744187451874618747187481874918750187511875218753187541875518756187571875818759187601876118762187631876418765187661876718768187691877018771187721877318774187751877618777187781877918780187811878218783187841878518786187871878818789187901879118792187931879418795187961879718798187991880018801188021880318804188051880618807188081880918810188111881218813188141881518816188171881818819188201882118822188231882418825188261882718828188291883018831188321883318834188351883618837188381883918840188411884218843188441884518846188471884818849188501885118852188531885418855188561885718858188591886018861188621886318864188651886618867188681886918870188711887218873188741887518876188771887818879188801888118882188831888418885188861888718888188891889018891188921889318894188951889618897188981889918900189011890218903189041890518906189071890818909189101891118912189131891418915189161891718918189191892018921189221892318924189251892618927189281892918930189311893218933189341893518936189371893818939189401894118942189431894418945189461894718948189491895018951189521895318954189551895618957189581895918960189611896218963189641896518966189671896818969189701897118972189731897418975189761897718978189791898018981189821898318984189851898618987189881898918990189911899218993189941899518996189971899818999190001900119002190031900419005190061900719008190091901019011190121901319014190151901619017190181901919020190211902219023190241902519026190271902819029190301903119032190331903419035190361903719038190391904019041190421904319044190451904619047190481904919050190511905219053190541905519056190571905819059190601906119062190631906419065190661906719068190691907019071190721907319074190751907619077190781907919080190811908219083190841908519086190871908819089190901909119092190931909419095190961909719098190991910019101191021910319104191051910619107191081910919110191111911219113191141911519116191171911819119191201912119122191231912419125191261912719128191291913019131191321913319134191351913619137191381913919140191411914219143191441914519146191471914819149191501915119152191531915419155191561915719158191591916019161191621916319164191651916619167191681916919170191711917219173191741917519176191771917819179191801918119182191831918419185191861918719188191891919019191191921919319194191951919619197191981919919200192011920219203192041920519206192071920819209192101921119212192131921419215192161921719218192191922019221192221922319224192251922619227192281922919230192311923219233192341923519236192371923819239192401924119242192431924419245192461924719248192491925019251192521925319254192551925619257192581925919260192611926219263192641926519266192671926819269192701927119272192731927419275192761927719278192791928019281192821928319284192851928619287192881928919290192911929219293192941929519296192971929819299193001930119302193031930419305193061930719308193091931019311193121931319314193151931619317193181931919320193211932219323193241932519326193271932819329193301933119332193331933419335193361933719338193391934019341193421934319344193451934619347193481934919350193511935219353193541935519356193571935819359193601936119362193631936419365193661936719368193691937019371193721937319374193751937619377193781937919380193811938219383193841938519386193871938819389193901939119392193931939419395193961939719398193991940019401194021940319404194051940619407194081940919410194111941219413194141941519416194171941819419194201942119422194231942419425194261942719428194291943019431194321943319434194351943619437194381943919440194411944219443194441944519446194471944819449194501945119452194531945419455194561945719458194591946019461194621946319464194651946619467194681946919470194711947219473194741947519476194771947819479194801948119482194831948419485194861948719488194891949019491194921949319494194951949619497194981949919500195011950219503195041950519506195071950819509195101951119512195131951419515195161951719518195191952019521195221952319524195251952619527195281952919530195311953219533195341953519536195371953819539195401954119542195431954419545195461954719548195491955019551195521955319554195551955619557195581955919560195611956219563195641956519566195671956819569195701957119572195731957419575195761957719578195791958019581195821958319584195851958619587195881958919590195911959219593195941959519596195971959819599196001960119602196031960419605196061960719608196091961019611196121961319614196151961619617196181961919620196211962219623196241962519626196271962819629196301963119632196331963419635196361963719638196391964019641196421964319644196451964619647196481964919650196511965219653196541965519656196571965819659196601966119662196631966419665196661966719668196691967019671196721967319674196751967619677196781967919680196811968219683196841968519686196871968819689196901969119692196931969419695196961969719698196991970019701197021970319704197051970619707197081970919710197111971219713197141971519716197171971819719197201972119722197231972419725197261972719728197291973019731197321973319734197351973619737197381973919740197411974219743197441974519746197471974819749197501975119752197531975419755197561975719758197591976019761197621976319764197651976619767197681976919770197711977219773197741977519776197771977819779197801978119782197831978419785197861978719788197891979019791197921979319794197951979619797197981979919800198011980219803198041980519806198071980819809198101981119812198131981419815198161981719818198191982019821198221982319824198251982619827198281982919830198311983219833198341983519836198371983819839198401984119842198431984419845198461984719848198491985019851198521985319854198551985619857198581985919860198611986219863198641986519866198671986819869198701987119872198731987419875198761987719878198791988019881198821988319884198851988619887198881988919890198911989219893198941989519896198971989819899199001990119902199031990419905199061990719908199091991019911199121991319914199151991619917199181991919920199211992219923199241992519926199271992819929199301993119932199331993419935199361993719938199391994019941199421994319944199451994619947199481994919950199511995219953199541995519956199571995819959199601996119962199631996419965199661996719968199691997019971199721997319974199751997619977199781997919980199811998219983199841998519986199871998819989199901999119992199931999419995199961999719998199992000020001200022000320004200052000620007200082000920010200112001220013200142001520016200172001820019200202002120022200232002420025200262002720028200292003020031200322003320034200352003620037200382003920040200412004220043200442004520046200472004820049200502005120052200532005420055200562005720058200592006020061200622006320064200652006620067200682006920070200712007220073200742007520076200772007820079200802008120082200832008420085200862008720088200892009020091200922009320094200952009620097200982009920100201012010220103201042010520106201072010820109201102011120112201132011420115201162011720118201192012020121201222012320124201252012620127201282012920130201312013220133201342013520136201372013820139201402014120142201432014420145201462014720148201492015020151201522015320154201552015620157201582015920160201612016220163201642016520166201672016820169201702017120172201732017420175201762017720178201792018020181201822018320184201852018620187201882018920190201912019220193201942019520196201972019820199202002020120202202032020420205202062020720208202092021020211202122021320214202152021620217202182021920220202212022220223202242022520226202272022820229202302023120232202332023420235202362023720238202392024020241202422024320244202452024620247202482024920250202512025220253202542025520256202572025820259202602026120262202632026420265202662026720268202692027020271202722027320274202752027620277202782027920280202812028220283202842028520286202872028820289202902029120292202932029420295202962029720298202992030020301203022030320304203052030620307203082030920310203112031220313203142031520316203172031820319203202032120322203232032420325203262032720328203292033020331203322033320334203352033620337203382033920340203412034220343203442034520346203472034820349203502035120352203532035420355203562035720358203592036020361203622036320364203652036620367203682036920370203712037220373203742037520376203772037820379203802038120382203832038420385203862038720388203892039020391203922039320394203952039620397203982039920400204012040220403204042040520406204072040820409204102041120412204132041420415204162041720418204192042020421204222042320424204252042620427204282042920430204312043220433204342043520436204372043820439204402044120442204432044420445204462044720448204492045020451204522045320454204552045620457204582045920460204612046220463204642046520466204672046820469204702047120472204732047420475204762047720478204792048020481204822048320484204852048620487204882048920490204912049220493204942049520496204972049820499205002050120502205032050420505205062050720508205092051020511205122051320514205152051620517205182051920520205212052220523205242052520526205272052820529205302053120532205332053420535205362053720538205392054020541205422054320544205452054620547205482054920550205512055220553205542055520556205572055820559205602056120562205632056420565205662056720568205692057020571205722057320574205752057620577205782057920580205812058220583205842058520586205872058820589205902059120592205932059420595205962059720598205992060020601206022060320604206052060620607206082060920610206112061220613206142061520616206172061820619206202062120622206232062420625206262062720628206292063020631206322063320634206352063620637206382063920640206412064220643206442064520646206472064820649206502065120652206532065420655206562065720658206592066020661206622066320664206652066620667206682066920670206712067220673206742067520676206772067820679206802068120682206832068420685206862068720688206892069020691206922069320694206952069620697206982069920700207012070220703207042070520706207072070820709207102071120712207132071420715207162071720718207192072020721207222072320724207252072620727207282072920730207312073220733207342073520736207372073820739207402074120742207432074420745207462074720748207492075020751207522075320754207552075620757207582075920760207612076220763207642076520766207672076820769207702077120772207732077420775207762077720778207792078020781207822078320784207852078620787207882078920790207912079220793207942079520796207972079820799208002080120802208032080420805208062080720808208092081020811208122081320814208152081620817208182081920820208212082220823208242082520826208272082820829208302083120832208332083420835208362083720838208392084020841208422084320844208452084620847208482084920850208512085220853208542085520856208572085820859208602086120862208632086420865208662086720868208692087020871208722087320874208752087620877208782087920880208812088220883208842088520886208872088820889208902089120892208932089420895208962089720898208992090020901209022090320904209052090620907209082090920910209112091220913209142091520916209172091820919209202092120922209232092420925209262092720928209292093020931209322093320934209352093620937209382093920940209412094220943209442094520946209472094820949209502095120952209532095420955209562095720958209592096020961209622096320964209652096620967209682096920970209712097220973209742097520976209772097820979209802098120982209832098420985209862098720988209892099020991209922099320994209952099620997209982099921000210012100221003210042100521006210072100821009210102101121012210132101421015210162101721018210192102021021210222102321024210252102621027210282102921030210312103221033210342103521036210372103821039210402104121042210432104421045210462104721048210492105021051210522105321054210552105621057210582105921060210612106221063210642106521066210672106821069210702107121072210732107421075210762107721078210792108021081210822108321084210852108621087210882108921090210912109221093210942109521096210972109821099211002110121102211032110421105211062110721108211092111021111211122111321114211152111621117211182111921120211212112221123211242112521126211272112821129211302113121132211332113421135211362113721138211392114021141211422114321144211452114621147211482114921150211512115221153211542115521156211572115821159211602116121162211632116421165211662116721168211692117021171211722117321174211752117621177211782117921180211812118221183211842118521186211872118821189211902119121192211932119421195211962119721198211992120021201212022120321204212052120621207212082120921210212112121221213212142121521216212172121821219212202122121222212232122421225212262122721228212292123021231212322123321234212352123621237212382123921240212412124221243212442124521246212472124821249212502125121252212532125421255212562125721258212592126021261212622126321264212652126621267212682126921270212712127221273212742127521276212772127821279212802128121282212832128421285212862128721288212892129021291212922129321294212952129621297212982129921300213012130221303213042130521306213072130821309213102131121312213132131421315213162131721318213192132021321213222132321324213252132621327213282132921330213312133221333213342133521336213372133821339213402134121342213432134421345213462134721348213492135021351213522135321354213552135621357213582135921360213612136221363213642136521366213672136821369213702137121372213732137421375213762137721378213792138021381213822138321384213852138621387213882138921390213912139221393213942139521396213972139821399214002140121402214032140421405214062140721408214092141021411214122141321414214152141621417214182141921420214212142221423214242142521426214272142821429214302143121432214332143421435214362143721438214392144021441214422144321444214452144621447214482144921450214512145221453214542145521456214572145821459214602146121462214632146421465214662146721468214692147021471214722147321474214752147621477214782147921480214812148221483214842148521486214872148821489214902149121492214932149421495214962149721498214992150021501215022150321504215052150621507215082150921510215112151221513215142151521516215172151821519215202152121522215232152421525215262152721528215292153021531215322153321534215352153621537215382153921540215412154221543215442154521546215472154821549215502155121552215532155421555215562155721558215592156021561215622156321564215652156621567215682156921570215712157221573215742157521576215772157821579215802158121582215832158421585215862158721588215892159021591215922159321594215952159621597215982159921600216012160221603216042160521606216072160821609216102161121612216132161421615216162161721618216192162021621216222162321624216252162621627216282162921630216312163221633216342163521636216372163821639216402164121642216432164421645216462164721648216492165021651216522165321654216552165621657216582165921660216612166221663216642166521666216672166821669216702167121672216732167421675216762167721678216792168021681216822168321684216852168621687216882168921690216912169221693216942169521696216972169821699217002170121702217032170421705217062170721708217092171021711217122171321714217152171621717217182171921720217212172221723217242172521726217272172821729217302173121732217332173421735217362173721738217392174021741217422174321744217452174621747217482174921750217512175221753217542175521756217572175821759217602176121762217632176421765217662176721768217692177021771217722177321774217752177621777217782177921780217812178221783217842178521786217872178821789217902179121792217932179421795217962179721798217992180021801218022180321804218052180621807218082180921810218112181221813218142181521816218172181821819218202182121822218232182421825218262182721828218292183021831218322183321834218352183621837218382183921840218412184221843218442184521846218472184821849218502185121852218532185421855218562185721858218592186021861218622186321864218652186621867218682186921870218712187221873218742187521876218772187821879218802188121882218832188421885218862188721888218892189021891218922189321894218952189621897218982189921900219012190221903219042190521906219072190821909219102191121912219132191421915219162191721918219192192021921219222192321924219252192621927219282192921930219312193221933219342193521936219372193821939219402194121942219432194421945219462194721948219492195021951219522195321954219552195621957219582195921960219612196221963219642196521966219672196821969219702197121972219732197421975219762197721978219792198021981219822198321984219852198621987219882198921990219912199221993219942199521996219972199821999220002200122002220032200422005220062200722008220092201022011220122201322014220152201622017220182201922020220212202222023220242202522026220272202822029220302203122032220332203422035220362203722038220392204022041220422204322044220452204622047220482204922050220512205222053220542205522056220572205822059220602206122062220632206422065220662206722068220692207022071220722207322074220752207622077220782207922080220812208222083220842208522086220872208822089220902209122092220932209422095220962209722098220992210022101221022210322104221052210622107221082210922110221112211222113221142211522116221172211822119221202212122122221232212422125221262212722128221292213022131221322213322134221352213622137221382213922140221412214222143221442214522146221472214822149221502215122152221532215422155221562215722158221592216022161221622216322164221652216622167221682216922170221712217222173221742217522176221772217822179221802218122182221832218422185221862218722188221892219022191221922219322194221952219622197221982219922200222012220222203222042220522206222072220822209222102221122212222132221422215222162221722218222192222022221222222222322224222252222622227222282222922230222312223222233222342223522236222372223822239222402224122242222432224422245222462224722248222492225022251222522225322254222552225622257222582225922260222612226222263222642226522266222672226822269222702227122272222732227422275222762227722278222792228022281222822228322284222852228622287222882228922290222912229222293222942229522296222972229822299223002230122302223032230422305223062230722308223092231022311223122231322314223152231622317223182231922320223212232222323223242232522326223272232822329223302233122332223332233422335223362233722338223392234022341223422234322344223452234622347223482234922350223512235222353223542235522356223572235822359223602236122362223632236422365223662236722368223692237022371223722237322374223752237622377223782237922380223812238222383223842238522386223872238822389223902239122392223932239422395223962239722398223992240022401224022240322404224052240622407224082240922410224112241222413224142241522416224172241822419224202242122422224232242422425224262242722428224292243022431224322243322434224352243622437224382243922440224412244222443224442244522446224472244822449224502245122452224532245422455224562245722458224592246022461224622246322464224652246622467224682246922470224712247222473224742247522476224772247822479224802248122482224832248422485224862248722488224892249022491224922249322494224952249622497224982249922500225012250222503225042250522506225072250822509225102251122512225132251422515225162251722518225192252022521225222252322524225252252622527225282252922530225312253222533225342253522536225372253822539225402254122542225432254422545225462254722548225492255022551225522255322554225552255622557225582255922560225612256222563225642256522566225672256822569225702257122572225732257422575225762257722578225792258022581225822258322584225852258622587225882258922590225912259222593225942259522596225972259822599226002260122602226032260422605226062260722608226092261022611226122261322614226152261622617226182261922620226212262222623226242262522626226272262822629226302263122632226332263422635226362263722638226392264022641226422264322644226452264622647226482264922650226512265222653226542265522656226572265822659226602266122662226632266422665226662266722668226692267022671226722267322674226752267622677226782267922680226812268222683226842268522686226872268822689226902269122692226932269422695226962269722698226992270022701227022270322704227052270622707227082270922710227112271222713227142271522716227172271822719227202272122722227232272422725227262272722728227292273022731227322273322734227352273622737227382273922740227412274222743227442274522746227472274822749227502275122752227532275422755227562275722758227592276022761227622276322764227652276622767227682276922770227712277222773227742277522776227772277822779227802278122782227832278422785227862278722788227892279022791227922279322794227952279622797227982279922800228012280222803228042280522806228072280822809228102281122812228132281422815228162281722818228192282022821228222282322824228252282622827228282282922830228312283222833228342283522836228372283822839228402284122842228432284422845228462284722848228492285022851228522285322854228552285622857228582285922860228612286222863228642286522866228672286822869228702287122872228732287422875228762287722878228792288022881228822288322884228852288622887228882288922890228912289222893228942289522896228972289822899229002290122902229032290422905229062290722908229092291022911229122291322914229152291622917229182291922920229212292222923229242292522926229272292822929229302293122932229332293422935229362293722938229392294022941229422294322944229452294622947229482294922950229512295222953229542295522956229572295822959229602296122962229632296422965229662296722968229692297022971229722297322974229752297622977229782297922980229812298222983229842298522986229872298822989229902299122992229932299422995229962299722998229992300023001230022300323004230052300623007230082300923010230112301223013230142301523016230172301823019230202302123022230232302423025230262302723028230292303023031230322303323034230352303623037230382303923040230412304223043230442304523046230472304823049230502305123052230532305423055230562305723058230592306023061230622306323064230652306623067230682306923070230712307223073230742307523076230772307823079230802308123082230832308423085230862308723088230892309023091230922309323094230952309623097230982309923100231012310223103231042310523106231072310823109231102311123112231132311423115231162311723118231192312023121231222312323124231252312623127231282312923130231312313223133231342313523136231372313823139231402314123142231432314423145231462314723148231492315023151231522315323154231552315623157231582315923160231612316223163231642316523166231672316823169231702317123172231732317423175231762317723178231792318023181231822318323184231852318623187231882318923190231912319223193231942319523196231972319823199232002320123202232032320423205232062320723208232092321023211232122321323214232152321623217232182321923220232212322223223232242322523226232272322823229232302323123232232332323423235232362323723238232392324023241232422324323244232452324623247232482324923250232512325223253232542325523256232572325823259232602326123262232632326423265232662326723268232692327023271232722327323274232752327623277232782327923280232812328223283232842328523286232872328823289232902329123292232932329423295232962329723298232992330023301233022330323304233052330623307233082330923310233112331223313233142331523316233172331823319233202332123322233232332423325233262332723328233292333023331233322333323334233352333623337233382333923340233412334223343233442334523346233472334823349233502335123352233532335423355233562335723358233592336023361233622336323364233652336623367233682336923370233712337223373233742337523376233772337823379233802338123382233832338423385233862338723388233892339023391233922339323394233952339623397233982339923400234012340223403234042340523406234072340823409234102341123412234132341423415234162341723418234192342023421234222342323424234252342623427234282342923430234312343223433234342343523436234372343823439234402344123442234432344423445234462344723448234492345023451234522345323454234552345623457234582345923460234612346223463234642346523466234672346823469234702347123472234732347423475234762347723478234792348023481234822348323484234852348623487234882348923490234912349223493234942349523496234972349823499235002350123502235032350423505235062350723508235092351023511235122351323514235152351623517235182351923520235212352223523235242352523526235272352823529235302353123532235332353423535235362353723538235392354023541235422354323544235452354623547235482354923550235512355223553235542355523556235572355823559235602356123562235632356423565235662356723568235692357023571235722357323574235752357623577235782357923580235812358223583235842358523586235872358823589235902359123592235932359423595235962359723598235992360023601236022360323604236052360623607236082360923610236112361223613236142361523616236172361823619236202362123622236232362423625236262362723628236292363023631236322363323634236352363623637236382363923640236412364223643236442364523646236472364823649236502365123652236532365423655236562365723658236592366023661236622366323664236652366623667236682366923670236712367223673236742367523676236772367823679236802368123682236832368423685236862368723688236892369023691236922369323694236952369623697236982369923700237012370223703237042370523706237072370823709237102371123712237132371423715237162371723718237192372023721237222372323724237252372623727237282372923730237312373223733237342373523736237372373823739237402374123742237432374423745237462374723748237492375023751237522375323754237552375623757237582375923760237612376223763237642376523766237672376823769237702377123772237732377423775237762377723778237792378023781237822378323784237852378623787237882378923790237912379223793237942379523796237972379823799238002380123802238032380423805238062380723808238092381023811238122381323814238152381623817238182381923820238212382223823238242382523826238272382823829238302383123832238332383423835238362383723838238392384023841238422384323844238452384623847238482384923850238512385223853238542385523856238572385823859238602386123862238632386423865238662386723868238692387023871238722387323874238752387623877238782387923880238812388223883238842388523886238872388823889238902389123892238932389423895238962389723898238992390023901239022390323904239052390623907239082390923910239112391223913239142391523916239172391823919239202392123922239232392423925239262392723928239292393023931239322393323934239352393623937239382393923940239412394223943239442394523946239472394823949239502395123952239532395423955239562395723958239592396023961239622396323964239652396623967239682396923970239712397223973239742397523976239772397823979239802398123982239832398423985239862398723988239892399023991239922399323994239952399623997239982399924000240012400224003240042400524006240072400824009240102401124012240132401424015240162401724018240192402024021240222402324024240252402624027240282402924030240312403224033240342403524036240372403824039240402404124042240432404424045240462404724048240492405024051240522405324054240552405624057240582405924060240612406224063240642406524066240672406824069240702407124072240732407424075240762407724078240792408024081240822408324084240852408624087240882408924090240912409224093240942409524096240972409824099241002410124102241032410424105241062410724108241092411024111241122411324114241152411624117241182411924120241212412224123241242412524126241272412824129241302413124132241332413424135241362413724138241392414024141241422414324144241452414624147241482414924150241512415224153241542415524156241572415824159241602416124162241632416424165241662416724168241692417024171241722417324174241752417624177241782417924180241812418224183241842418524186241872418824189241902419124192241932419424195241962419724198241992420024201242022420324204242052420624207242082420924210242112421224213242142421524216242172421824219242202422124222242232422424225242262422724228242292423024231242322423324234242352423624237242382423924240242412424224243242442424524246242472424824249242502425124252242532425424255242562425724258242592426024261242622426324264242652426624267242682426924270242712427224273242742427524276242772427824279242802428124282242832428424285242862428724288242892429024291242922429324294242952429624297242982429924300243012430224303243042430524306243072430824309243102431124312243132431424315243162431724318243192432024321243222432324324243252432624327243282432924330243312433224333243342433524336243372433824339243402434124342243432434424345243462434724348243492435024351243522435324354243552435624357243582435924360243612436224363243642436524366243672436824369243702437124372243732437424375243762437724378243792438024381243822438324384243852438624387243882438924390243912439224393243942439524396243972439824399244002440124402244032440424405244062440724408244092441024411244122441324414244152441624417244182441924420244212442224423244242442524426244272442824429244302443124432244332443424435244362443724438244392444024441244422444324444244452444624447244482444924450244512445224453244542445524456244572445824459244602446124462244632446424465244662446724468244692447024471244722447324474244752447624477244782447924480244812448224483244842448524486244872448824489244902449124492244932449424495244962449724498244992450024501245022450324504245052450624507245082450924510245112451224513245142451524516245172451824519245202452124522245232452424525245262452724528245292453024531245322453324534245352453624537245382453924540245412454224543245442454524546245472454824549245502455124552245532455424555245562455724558245592456024561245622456324564245652456624567245682456924570245712457224573245742457524576245772457824579245802458124582245832458424585245862458724588245892459024591245922459324594245952459624597245982459924600246012460224603246042460524606246072460824609246102461124612246132461424615246162461724618246192462024621246222462324624246252462624627246282462924630246312463224633246342463524636246372463824639246402464124642246432464424645246462464724648246492465024651246522465324654246552465624657246582465924660246612466224663246642466524666246672466824669246702467124672246732467424675246762467724678246792468024681246822468324684246852468624687246882468924690246912469224693246942469524696246972469824699247002470124702247032470424705247062470724708247092471024711247122471324714247152471624717247182471924720247212472224723247242472524726247272472824729247302473124732247332473424735247362473724738247392474024741247422474324744247452474624747247482474924750247512475224753247542475524756247572475824759247602476124762247632476424765247662476724768247692477024771247722477324774247752477624777247782477924780247812478224783247842478524786247872478824789247902479124792247932479424795247962479724798247992480024801248022480324804248052480624807248082480924810248112481224813248142481524816248172481824819248202482124822248232482424825248262482724828248292483024831248322483324834248352483624837248382483924840248412484224843248442484524846248472484824849248502485124852248532485424855248562485724858248592486024861248622486324864248652486624867248682486924870248712487224873248742487524876248772487824879248802488124882248832488424885248862488724888248892489024891248922489324894248952489624897248982489924900249012490224903249042490524906249072490824909249102491124912249132491424915249162491724918249192492024921249222492324924249252492624927249282492924930249312493224933249342493524936249372493824939249402494124942249432494424945249462494724948249492495024951249522495324954249552495624957249582495924960249612496224963249642496524966249672496824969249702497124972249732497424975249762497724978249792498024981249822498324984249852498624987249882498924990249912499224993249942499524996249972499824999250002500125002250032500425005250062500725008250092501025011250122501325014250152501625017250182501925020250212502225023250242502525026250272502825029250302503125032250332503425035250362503725038250392504025041250422504325044250452504625047250482504925050250512505225053250542505525056250572505825059250602506125062250632506425065250662506725068250692507025071250722507325074250752507625077250782507925080250812508225083250842508525086250872508825089250902509125092250932509425095250962509725098250992510025101251022510325104251052510625107251082510925110251112511225113251142511525116251172511825119251202512125122251232512425125251262512725128251292513025131251322513325134251352513625137251382513925140251412514225143251442514525146251472514825149251502515125152251532515425155251562515725158251592516025161251622516325164251652516625167251682516925170251712517225173251742517525176251772517825179251802518125182251832518425185251862518725188251892519025191251922519325194251952519625197251982519925200252012520225203252042520525206252072520825209252102521125212252132521425215252162521725218252192522025221252222522325224252252522625227252282522925230252312523225233252342523525236252372523825239252402524125242252432524425245252462524725248252492525025251252522525325254252552525625257252582525925260252612526225263252642526525266252672526825269252702527125272252732527425275252762527725278252792528025281252822528325284252852528625287252882528925290252912529225293252942529525296252972529825299253002530125302253032530425305253062530725308253092531025311253122531325314253152531625317253182531925320253212532225323253242532525326253272532825329253302533125332253332533425335253362533725338253392534025341253422534325344253452534625347253482534925350253512535225353253542535525356253572535825359253602536125362253632536425365253662536725368253692537025371253722537325374253752537625377253782537925380253812538225383253842538525386253872538825389253902539125392253932539425395253962539725398253992540025401254022540325404254052540625407254082540925410254112541225413254142541525416254172541825419254202542125422254232542425425254262542725428254292543025431254322543325434254352543625437254382543925440254412544225443254442544525446254472544825449254502545125452254532545425455254562545725458254592546025461254622546325464254652546625467254682546925470254712547225473254742547525476254772547825479254802548125482254832548425485254862548725488254892549025491254922549325494254952549625497254982549925500255012550225503255042550525506255072550825509255102551125512255132551425515255162551725518255192552025521255222552325524255252552625527255282552925530255312553225533255342553525536255372553825539255402554125542255432554425545255462554725548255492555025551255522555325554255552555625557255582555925560255612556225563255642556525566255672556825569255702557125572255732557425575255762557725578255792558025581255822558325584255852558625587255882558925590255912559225593255942559525596255972559825599256002560125602256032560425605256062560725608256092561025611256122561325614256152561625617256182561925620256212562225623256242562525626256272562825629256302563125632256332563425635256362563725638256392564025641256422564325644256452564625647256482564925650256512565225653256542565525656256572565825659256602566125662256632566425665256662566725668256692567025671256722567325674256752567625677256782567925680256812568225683256842568525686256872568825689256902569125692256932569425695256962569725698256992570025701257022570325704257052570625707257082570925710257112571225713257142571525716257172571825719257202572125722257232572425725257262572725728257292573025731257322573325734257352573625737257382573925740257412574225743257442574525746257472574825749257502575125752257532575425755257562575725758257592576025761257622576325764257652576625767257682576925770257712577225773257742577525776257772577825779257802578125782257832578425785257862578725788257892579025791257922579325794257952579625797257982579925800258012580225803258042580525806258072580825809258102581125812258132581425815258162581725818258192582025821258222582325824258252582625827258282582925830258312583225833258342583525836258372583825839258402584125842258432584425845258462584725848258492585025851258522585325854258552585625857258582585925860258612586225863258642586525866258672586825869258702587125872258732587425875258762587725878258792588025881258822588325884258852588625887258882588925890258912589225893258942589525896258972589825899259002590125902259032590425905259062590725908259092591025911259122591325914259152591625917259182591925920259212592225923259242592525926259272592825929259302593125932259332593425935259362593725938259392594025941259422594325944259452594625947259482594925950259512595225953259542595525956259572595825959259602596125962259632596425965259662596725968259692597025971259722597325974259752597625977259782597925980259812598225983259842598525986259872598825989259902599125992259932599425995259962599725998259992600026001260022600326004260052600626007260082600926010260112601226013260142601526016260172601826019260202602126022260232602426025260262602726028260292603026031260322603326034260352603626037260382603926040260412604226043260442604526046260472604826049260502605126052260532605426055260562605726058260592606026061260622606326064260652606626067260682606926070260712607226073260742607526076260772607826079260802608126082260832608426085260862608726088260892609026091260922609326094260952609626097260982609926100261012610226103261042610526106261072610826109261102611126112261132611426115261162611726118261192612026121261222612326124261252612626127261282612926130261312613226133261342613526136261372613826139261402614126142261432614426145261462614726148261492615026151261522615326154261552615626157261582615926160261612616226163261642616526166261672616826169261702617126172261732617426175261762617726178261792618026181261822618326184261852618626187261882618926190261912619226193261942619526196261972619826199262002620126202262032620426205262062620726208262092621026211262122621326214262152621626217262182621926220262212622226223262242622526226262272622826229262302623126232262332623426235262362623726238262392624026241262422624326244262452624626247262482624926250262512625226253262542625526256262572625826259262602626126262262632626426265262662626726268262692627026271262722627326274262752627626277262782627926280262812628226283262842628526286262872628826289262902629126292262932629426295262962629726298262992630026301263022630326304263052630626307263082630926310263112631226313263142631526316263172631826319263202632126322263232632426325263262632726328263292633026331263322633326334263352633626337263382633926340263412634226343263442634526346263472634826349263502635126352263532635426355263562635726358263592636026361263622636326364263652636626367263682636926370263712637226373263742637526376263772637826379263802638126382263832638426385263862638726388263892639026391263922639326394263952639626397263982639926400264012640226403264042640526406264072640826409264102641126412264132641426415264162641726418264192642026421264222642326424264252642626427264282642926430264312643226433264342643526436264372643826439264402644126442264432644426445264462644726448264492645026451264522645326454264552645626457264582645926460264612646226463264642646526466264672646826469264702647126472264732647426475264762647726478264792648026481264822648326484264852648626487264882648926490264912649226493264942649526496264972649826499265002650126502265032650426505265062650726508265092651026511265122651326514265152651626517265182651926520265212652226523265242652526526265272652826529265302653126532265332653426535265362653726538265392654026541265422654326544265452654626547265482654926550265512655226553265542655526556265572655826559265602656126562265632656426565265662656726568265692657026571265722657326574265752657626577265782657926580265812658226583265842658526586265872658826589265902659126592265932659426595265962659726598265992660026601266022660326604266052660626607266082660926610266112661226613266142661526616266172661826619266202662126622266232662426625266262662726628266292663026631266322663326634266352663626637266382663926640266412664226643266442664526646266472664826649266502665126652266532665426655266562665726658266592666026661266622666326664266652666626667266682666926670266712667226673266742667526676266772667826679266802668126682266832668426685266862668726688266892669026691266922669326694266952669626697266982669926700267012670226703267042670526706267072670826709267102671126712267132671426715267162671726718267192672026721267222672326724267252672626727267282672926730267312673226733267342673526736267372673826739267402674126742267432674426745267462674726748267492675026751267522675326754267552675626757267582675926760267612676226763267642676526766267672676826769267702677126772267732677426775267762677726778267792678026781267822678326784267852678626787267882678926790267912679226793267942679526796267972679826799268002680126802268032680426805268062680726808268092681026811268122681326814268152681626817268182681926820268212682226823268242682526826268272682826829268302683126832268332683426835268362683726838268392684026841268422684326844268452684626847268482684926850268512685226853268542685526856268572685826859268602686126862268632686426865268662686726868268692687026871268722687326874268752687626877268782687926880268812688226883268842688526886268872688826889268902689126892268932689426895268962689726898268992690026901269022690326904269052690626907269082690926910269112691226913269142691526916269172691826919269202692126922269232692426925269262692726928269292693026931269322693326934269352693626937269382693926940269412694226943269442694526946269472694826949269502695126952269532695426955269562695726958269592696026961269622696326964269652696626967269682696926970269712697226973269742697526976269772697826979269802698126982269832698426985269862698726988269892699026991269922699326994269952699626997269982699927000270012700227003270042700527006270072700827009270102701127012270132701427015270162701727018270192702027021270222702327024270252702627027270282702927030270312703227033270342703527036270372703827039270402704127042270432704427045270462704727048270492705027051270522705327054270552705627057270582705927060270612706227063270642706527066270672706827069270702707127072270732707427075270762707727078270792708027081270822708327084270852708627087270882708927090270912709227093270942709527096270972709827099271002710127102271032710427105271062710727108271092711027111271122711327114271152711627117271182711927120271212712227123271242712527126271272712827129271302713127132271332713427135271362713727138271392714027141271422714327144271452714627147271482714927150271512715227153271542715527156271572715827159271602716127162271632716427165271662716727168271692717027171271722717327174271752717627177271782717927180271812718227183271842718527186271872718827189271902719127192271932719427195271962719727198271992720027201272022720327204272052720627207272082720927210272112721227213272142721527216272172721827219272202722127222272232722427225272262722727228272292723027231272322723327234272352723627237272382723927240272412724227243272442724527246272472724827249272502725127252272532725427255272562725727258272592726027261272622726327264272652726627267272682726927270272712727227273272742727527276272772727827279272802728127282272832728427285272862728727288272892729027291272922729327294272952729627297272982729927300273012730227303273042730527306273072730827309273102731127312273132731427315273162731727318273192732027321273222732327324273252732627327273282732927330273312733227333273342733527336273372733827339273402734127342273432734427345273462734727348273492735027351273522735327354273552735627357273582735927360273612736227363273642736527366273672736827369273702737127372273732737427375273762737727378273792738027381273822738327384273852738627387273882738927390273912739227393273942739527396273972739827399274002740127402274032740427405274062740727408274092741027411274122741327414274152741627417274182741927420274212742227423274242742527426274272742827429274302743127432274332743427435274362743727438274392744027441274422744327444274452744627447274482744927450274512745227453274542745527456274572745827459274602746127462274632746427465274662746727468274692747027471274722747327474274752747627477274782747927480274812748227483274842748527486274872748827489274902749127492274932749427495274962749727498274992750027501275022750327504275052750627507275082750927510275112751227513275142751527516275172751827519275202752127522275232752427525275262752727528275292753027531275322753327534275352753627537275382753927540275412754227543275442754527546275472754827549275502755127552275532755427555275562755727558275592756027561275622756327564275652756627567275682756927570275712757227573275742757527576275772757827579275802758127582275832758427585275862758727588275892759027591275922759327594275952759627597275982759927600276012760227603276042760527606276072760827609276102761127612276132761427615276162761727618276192762027621276222762327624276252762627627276282762927630276312763227633276342763527636276372763827639276402764127642276432764427645276462764727648276492765027651276522765327654276552765627657276582765927660276612766227663276642766527666276672766827669276702767127672276732767427675276762767727678276792768027681276822768327684276852768627687276882768927690276912769227693276942769527696276972769827699277002770127702277032770427705277062770727708277092771027711277122771327714277152771627717277182771927720277212772227723277242772527726277272772827729277302773127732277332773427735277362773727738277392774027741277422774327744277452774627747277482774927750277512775227753277542775527756277572775827759277602776127762277632776427765277662776727768277692777027771277722777327774277752777627777277782777927780277812778227783277842778527786277872778827789277902779127792277932779427795277962779727798277992780027801278022780327804278052780627807278082780927810278112781227813278142781527816278172781827819278202782127822278232782427825278262782727828278292783027831278322783327834278352783627837278382783927840278412784227843278442784527846278472784827849278502785127852278532785427855278562785727858278592786027861278622786327864278652786627867278682786927870278712787227873278742787527876278772787827879278802788127882278832788427885278862788727888278892789027891278922789327894278952789627897278982789927900279012790227903279042790527906279072790827909279102791127912279132791427915279162791727918279192792027921279222792327924279252792627927279282792927930279312793227933279342793527936279372793827939279402794127942279432794427945279462794727948279492795027951279522795327954279552795627957279582795927960279612796227963279642796527966279672796827969279702797127972279732797427975279762797727978279792798027981279822798327984279852798627987279882798927990279912799227993279942799527996279972799827999280002800128002280032800428005280062800728008280092801028011280122801328014280152801628017280182801928020280212802228023280242802528026280272802828029280302803128032280332803428035280362803728038280392804028041280422804328044280452804628047280482804928050280512805228053280542805528056280572805828059280602806128062280632806428065280662806728068280692807028071280722807328074280752807628077280782807928080280812808228083280842808528086280872808828089280902809128092280932809428095280962809728098280992810028101281022810328104281052810628107281082810928110281112811228113281142811528116281172811828119281202812128122281232812428125281262812728128281292813028131281322813328134281352813628137281382813928140281412814228143281442814528146281472814828149281502815128152281532815428155281562815728158281592816028161281622816328164281652816628167281682816928170281712817228173281742817528176281772817828179281802818128182281832818428185281862818728188281892819028191281922819328194281952819628197281982819928200282012820228203282042820528206282072820828209282102821128212282132821428215282162821728218282192822028221282222822328224282252822628227282282822928230282312823228233282342823528236282372823828239282402824128242282432824428245282462824728248282492825028251282522825328254282552825628257282582825928260282612826228263282642826528266282672826828269282702827128272282732827428275282762827728278282792828028281282822828328284282852828628287282882828928290282912829228293282942829528296282972829828299283002830128302283032830428305283062830728308283092831028311283122831328314283152831628317283182831928320283212832228323283242832528326283272832828329283302833128332283332833428335283362833728338283392834028341283422834328344283452834628347283482834928350283512835228353283542835528356283572835828359283602836128362283632836428365283662836728368283692837028371283722837328374283752837628377283782837928380283812838228383283842838528386283872838828389283902839128392283932839428395283962839728398283992840028401284022840328404284052840628407284082840928410284112841228413284142841528416284172841828419284202842128422284232842428425284262842728428284292843028431284322843328434284352843628437284382843928440284412844228443284442844528446284472844828449284502845128452284532845428455284562845728458284592846028461284622846328464284652846628467284682846928470284712847228473284742847528476284772847828479284802848128482284832848428485284862848728488284892849028491284922849328494284952849628497284982849928500285012850228503285042850528506285072850828509285102851128512285132851428515285162851728518285192852028521285222852328524285252852628527285282852928530285312853228533285342853528536285372853828539285402854128542285432854428545285462854728548285492855028551285522855328554285552855628557285582855928560285612856228563285642856528566285672856828569285702857128572285732857428575285762857728578285792858028581285822858328584285852858628587285882858928590285912859228593285942859528596285972859828599286002860128602286032860428605286062860728608286092861028611286122861328614286152861628617286182861928620286212862228623286242862528626286272862828629286302863128632286332863428635286362863728638286392864028641286422864328644286452864628647286482864928650286512865228653286542865528656286572865828659286602866128662286632866428665286662866728668286692867028671286722867328674286752867628677286782867928680286812868228683286842868528686286872868828689286902869128692286932869428695286962869728698286992870028701287022870328704287052870628707287082870928710287112871228713287142871528716287172871828719287202872128722287232872428725287262872728728287292873028731287322873328734287352873628737287382873928740287412874228743287442874528746287472874828749287502875128752287532875428755287562875728758287592876028761287622876328764287652876628767287682876928770287712877228773287742877528776287772877828779287802878128782287832878428785287862878728788287892879028791287922879328794287952879628797287982879928800288012880228803288042880528806288072880828809288102881128812288132881428815288162881728818288192882028821288222882328824288252882628827288282882928830288312883228833288342883528836288372883828839288402884128842288432884428845288462884728848288492885028851288522885328854288552885628857288582885928860288612886228863288642886528866288672886828869288702887128872288732887428875288762887728878288792888028881288822888328884288852888628887288882888928890288912889228893288942889528896288972889828899289002890128902289032890428905289062890728908289092891028911289122891328914289152891628917289182891928920289212892228923289242892528926289272892828929289302893128932289332893428935289362893728938289392894028941289422894328944289452894628947289482894928950289512895228953289542895528956289572895828959289602896128962289632896428965289662896728968289692897028971289722897328974289752897628977289782897928980289812898228983289842898528986289872898828989289902899128992289932899428995289962899728998289992900029001290022900329004290052900629007290082900929010290112901229013290142901529016290172901829019290202902129022290232902429025290262902729028290292903029031290322903329034290352903629037290382903929040290412904229043290442904529046290472904829049290502905129052290532905429055290562905729058290592906029061290622906329064290652906629067290682906929070290712907229073290742907529076290772907829079290802908129082290832908429085290862908729088290892909029091290922909329094290952909629097290982909929100291012910229103291042910529106291072910829109291102911129112291132911429115291162911729118291192912029121291222912329124291252912629127291282912929130291312913229133291342913529136291372913829139291402914129142291432914429145291462914729148291492915029151291522915329154291552915629157291582915929160291612916229163291642916529166291672916829169291702917129172291732917429175291762917729178291792918029181291822918329184291852918629187291882918929190291912919229193291942919529196291972919829199292002920129202292032920429205292062920729208292092921029211292122921329214292152921629217292182921929220292212922229223292242922529226292272922829229292302923129232292332923429235292362923729238292392924029241292422924329244292452924629247292482924929250292512925229253292542925529256292572925829259292602926129262292632926429265292662926729268292692927029271292722927329274292752927629277292782927929280292812928229283292842928529286292872928829289292902929129292292932929429295292962929729298292992930029301293022930329304293052930629307293082930929310293112931229313293142931529316293172931829319293202932129322293232932429325293262932729328293292933029331293322933329334293352933629337293382933929340293412934229343293442934529346293472934829349293502935129352293532935429355293562935729358293592936029361293622936329364293652936629367293682936929370293712937229373293742937529376293772937829379293802938129382293832938429385293862938729388293892939029391293922939329394293952939629397293982939929400294012940229403294042940529406294072940829409294102941129412294132941429415294162941729418294192942029421294222942329424294252942629427294282942929430294312943229433294342943529436294372943829439294402944129442294432944429445294462944729448294492945029451294522945329454294552945629457294582945929460294612946229463294642946529466294672946829469294702947129472294732947429475294762947729478294792948029481294822948329484294852948629487294882948929490294912949229493294942949529496294972949829499295002950129502295032950429505295062950729508295092951029511295122951329514295152951629517295182951929520295212952229523295242952529526295272952829529295302953129532295332953429535295362953729538295392954029541295422954329544295452954629547295482954929550295512955229553295542955529556295572955829559295602956129562295632956429565295662956729568295692957029571295722957329574295752957629577295782957929580295812958229583295842958529586295872958829589295902959129592295932959429595295962959729598295992960029601296022960329604296052960629607296082960929610296112961229613296142961529616296172961829619296202962129622296232962429625296262962729628296292963029631296322963329634296352963629637296382963929640296412964229643296442964529646296472964829649296502965129652296532965429655296562965729658296592966029661296622966329664296652966629667296682966929670296712967229673296742967529676296772967829679296802968129682296832968429685296862968729688296892969029691296922969329694296952969629697296982969929700297012970229703297042970529706297072970829709297102971129712297132971429715297162971729718297192972029721297222972329724297252972629727297282972929730297312973229733297342973529736297372973829739297402974129742297432974429745297462974729748297492975029751297522975329754297552975629757297582975929760297612976229763297642976529766297672976829769297702977129772297732977429775297762977729778297792978029781297822978329784297852978629787297882978929790297912979229793297942979529796297972979829799298002980129802298032980429805298062980729808298092981029811298122981329814298152981629817298182981929820298212982229823298242982529826298272982829829298302983129832298332983429835298362983729838298392984029841298422984329844298452984629847298482984929850298512985229853298542985529856298572985829859298602986129862298632986429865298662986729868298692987029871298722987329874298752987629877298782987929880298812988229883298842988529886298872988829889298902989129892298932989429895298962989729898298992990029901299022990329904299052990629907299082990929910299112991229913299142991529916299172991829919299202992129922299232992429925299262992729928299292993029931299322993329934299352993629937299382993929940299412994229943299442994529946299472994829949299502995129952299532995429955299562995729958299592996029961299622996329964299652996629967299682996929970299712997229973299742997529976299772997829979299802998129982299832998429985299862998729988299892999029991299922999329994299952999629997299982999930000300013000230003300043000530006300073000830009300103001130012300133001430015300163001730018300193002030021300223002330024300253002630027300283002930030300313003230033300343003530036300373003830039300403004130042300433004430045300463004730048300493005030051300523005330054300553005630057300583005930060300613006230063300643006530066300673006830069300703007130072300733007430075300763007730078300793008030081300823008330084300853008630087300883008930090300913009230093300943009530096300973009830099301003010130102301033010430105301063010730108301093011030111301123011330114301153011630117301183011930120301213012230123301243012530126301273012830129301303013130132301333013430135301363013730138301393014030141301423014330144301453014630147301483014930150301513015230153301543015530156301573015830159301603016130162301633016430165301663016730168301693017030171301723017330174301753017630177301783017930180301813018230183301843018530186301873018830189301903019130192301933019430195301963019730198301993020030201302023020330204302053020630207302083020930210302113021230213302143021530216302173021830219302203022130222302233022430225302263022730228302293023030231302323023330234302353023630237302383023930240302413024230243302443024530246302473024830249302503025130252302533025430255302563025730258302593026030261302623026330264302653026630267302683026930270302713027230273302743027530276302773027830279302803028130282302833028430285302863028730288302893029030291302923029330294302953029630297302983029930300303013030230303303043030530306303073030830309303103031130312303133031430315303163031730318303193032030321303223032330324303253032630327303283032930330303313033230333303343033530336303373033830339303403034130342303433034430345303463034730348303493035030351303523035330354303553035630357303583035930360303613036230363303643036530366303673036830369303703037130372303733037430375303763037730378303793038030381303823038330384303853038630387303883038930390303913039230393303943039530396303973039830399304003040130402304033040430405304063040730408304093041030411304123041330414304153041630417304183041930420304213042230423304243042530426304273042830429304303043130432304333043430435304363043730438304393044030441304423044330444304453044630447304483044930450304513045230453304543045530456304573045830459304603046130462304633046430465304663046730468304693047030471304723047330474304753047630477304783047930480304813048230483304843048530486304873048830489304903049130492304933049430495304963049730498304993050030501305023050330504305053050630507305083050930510305113051230513305143051530516305173051830519305203052130522305233052430525305263052730528305293053030531305323053330534305353053630537305383053930540305413054230543305443054530546305473054830549305503055130552305533055430555305563055730558305593056030561305623056330564305653056630567305683056930570305713057230573305743057530576305773057830579305803058130582305833058430585305863058730588305893059030591305923059330594305953059630597305983059930600306013060230603306043060530606306073060830609306103061130612306133061430615306163061730618306193062030621306223062330624306253062630627306283062930630306313063230633306343063530636306373063830639306403064130642306433064430645306463064730648306493065030651306523065330654306553065630657306583065930660306613066230663306643066530666306673066830669306703067130672306733067430675306763067730678306793068030681306823068330684306853068630687306883068930690306913069230693306943069530696306973069830699307003070130702307033070430705307063070730708307093071030711307123071330714307153071630717307183071930720307213072230723307243072530726307273072830729307303073130732307333073430735307363073730738307393074030741307423074330744307453074630747307483074930750307513075230753307543075530756307573075830759307603076130762307633076430765307663076730768307693077030771307723077330774307753077630777307783077930780307813078230783307843078530786307873078830789307903079130792307933079430795307963079730798307993080030801308023080330804308053080630807308083080930810308113081230813308143081530816308173081830819308203082130822308233082430825308263082730828308293083030831308323083330834308353083630837308383083930840308413084230843308443084530846308473084830849308503085130852308533085430855308563085730858308593086030861308623086330864308653086630867308683086930870308713087230873308743087530876308773087830879308803088130882308833088430885308863088730888308893089030891308923089330894308953089630897308983089930900309013090230903309043090530906309073090830909309103091130912309133091430915309163091730918309193092030921309223092330924309253092630927309283092930930309313093230933309343093530936309373093830939309403094130942309433094430945309463094730948309493095030951309523095330954309553095630957309583095930960309613096230963309643096530966309673096830969309703097130972309733097430975309763097730978309793098030981309823098330984309853098630987309883098930990309913099230993309943099530996309973099830999310003100131002310033100431005310063100731008310093101031011310123101331014310153101631017310183101931020310213102231023310243102531026310273102831029310303103131032310333103431035310363103731038310393104031041310423104331044310453104631047310483104931050310513105231053310543105531056310573105831059310603106131062310633106431065310663106731068310693107031071310723107331074310753107631077310783107931080310813108231083310843108531086310873108831089310903109131092310933109431095310963109731098310993110031101311023110331104311053110631107311083110931110311113111231113311143111531116311173111831119311203112131122311233112431125311263112731128311293113031131311323113331134311353113631137311383113931140311413114231143311443114531146311473114831149311503115131152311533115431155311563115731158311593116031161311623116331164311653116631167311683116931170311713117231173311743117531176311773117831179311803118131182311833118431185311863118731188311893119031191311923119331194311953119631197311983119931200312013120231203312043120531206312073120831209312103121131212312133121431215312163121731218312193122031221312223122331224312253122631227312283122931230312313123231233312343123531236312373123831239312403124131242312433124431245312463124731248312493125031251312523125331254312553125631257312583125931260312613126231263312643126531266312673126831269312703127131272312733127431275312763127731278312793128031281312823128331284312853128631287312883128931290312913129231293312943129531296312973129831299313003130131302313033130431305313063130731308313093131031311313123131331314313153131631317313183131931320313213132231323313243132531326313273132831329313303133131332313333133431335313363133731338313393134031341313423134331344313453134631347313483134931350313513135231353313543135531356313573135831359313603136131362313633136431365313663136731368313693137031371313723137331374313753137631377313783137931380313813138231383313843138531386313873138831389313903139131392313933139431395313963139731398313993140031401314023140331404314053140631407314083140931410314113141231413314143141531416314173141831419314203142131422314233142431425314263142731428314293143031431314323143331434314353143631437314383143931440314413144231443314443144531446314473144831449314503145131452314533145431455314563145731458314593146031461314623146331464314653146631467314683146931470314713147231473314743147531476314773147831479314803148131482314833148431485314863148731488314893149031491314923149331494314953149631497314983149931500315013150231503315043150531506315073150831509315103151131512315133151431515315163151731518315193152031521315223152331524315253152631527315283152931530315313153231533315343153531536315373153831539315403154131542315433154431545315463154731548315493155031551315523155331554315553155631557315583155931560315613156231563315643156531566315673156831569315703157131572315733157431575315763157731578315793158031581315823158331584315853158631587315883158931590315913159231593315943159531596315973159831599316003160131602316033160431605316063160731608316093161031611316123161331614316153161631617316183161931620316213162231623316243162531626316273162831629316303163131632316333163431635316363163731638316393164031641316423164331644316453164631647316483164931650316513165231653316543165531656316573165831659316603166131662316633166431665316663166731668316693167031671316723167331674316753167631677316783167931680316813168231683316843168531686316873168831689316903169131692316933169431695316963169731698316993170031701317023170331704317053170631707317083170931710317113171231713317143171531716317173171831719317203172131722317233172431725317263172731728317293173031731317323173331734317353173631737317383173931740317413174231743317443174531746317473174831749317503175131752317533175431755317563175731758317593176031761317623176331764317653176631767317683176931770317713177231773317743177531776317773177831779317803178131782317833178431785317863178731788317893179031791317923179331794317953179631797317983179931800318013180231803318043180531806318073180831809318103181131812318133181431815318163181731818318193182031821318223182331824318253182631827318283182931830318313183231833318343183531836318373183831839318403184131842318433184431845318463184731848318493185031851318523185331854318553185631857318583185931860318613186231863318643186531866318673186831869318703187131872318733187431875318763187731878318793188031881318823188331884318853188631887318883188931890318913189231893318943189531896318973189831899319003190131902319033190431905319063190731908319093191031911319123191331914319153191631917319183191931920319213192231923319243192531926319273192831929319303193131932319333193431935319363193731938319393194031941319423194331944319453194631947319483194931950319513195231953319543195531956319573195831959319603196131962319633196431965319663196731968319693197031971319723197331974319753197631977319783197931980319813198231983319843198531986319873198831989319903199131992319933199431995319963199731998319993200032001320023200332004320053200632007320083200932010320113201232013320143201532016320173201832019320203202132022320233202432025320263202732028320293203032031320323203332034320353203632037320383203932040320413204232043320443204532046320473204832049320503205132052320533205432055320563205732058320593206032061320623206332064320653206632067320683206932070320713207232073320743207532076320773207832079320803208132082320833208432085320863208732088320893209032091320923209332094320953209632097320983209932100321013210232103321043210532106321073210832109321103211132112321133211432115321163211732118321193212032121321223212332124321253212632127321283212932130321313213232133321343213532136321373213832139321403214132142321433214432145321463214732148321493215032151321523215332154321553215632157321583215932160321613216232163321643216532166321673216832169321703217132172321733217432175321763217732178321793218032181321823218332184321853218632187321883218932190321913219232193321943219532196321973219832199322003220132202322033220432205322063220732208322093221032211322123221332214322153221632217322183221932220322213222232223322243222532226322273222832229322303223132232322333223432235322363223732238322393224032241322423224332244322453224632247322483224932250322513225232253322543225532256322573225832259322603226132262322633226432265322663226732268322693227032271322723227332274322753227632277322783227932280322813228232283322843228532286322873228832289322903229132292322933229432295322963229732298322993230032301323023230332304323053230632307323083230932310323113231232313323143231532316323173231832319323203232132322323233232432325323263232732328323293233032331323323233332334323353233632337323383233932340323413234232343323443234532346323473234832349323503235132352323533235432355323563235732358323593236032361323623236332364323653236632367323683236932370323713237232373323743237532376323773237832379323803238132382323833238432385323863238732388323893239032391323923239332394323953239632397323983239932400324013240232403324043240532406324073240832409324103241132412324133241432415324163241732418324193242032421324223242332424324253242632427324283242932430324313243232433324343243532436324373243832439324403244132442324433244432445324463244732448324493245032451324523245332454324553245632457324583245932460324613246232463324643246532466324673246832469324703247132472324733247432475324763247732478324793248032481324823248332484324853248632487324883248932490324913249232493324943249532496324973249832499325003250132502325033250432505325063250732508325093251032511325123251332514325153251632517325183251932520325213252232523325243252532526325273252832529325303253132532325333253432535325363253732538325393254032541325423254332544325453254632547325483254932550325513255232553325543255532556325573255832559325603256132562325633256432565325663256732568325693257032571325723257332574325753257632577325783257932580325813258232583325843258532586325873258832589325903259132592325933259432595325963259732598325993260032601326023260332604326053260632607326083260932610326113261232613326143261532616326173261832619326203262132622326233262432625326263262732628326293263032631326323263332634326353263632637326383263932640326413264232643326443264532646326473264832649326503265132652326533265432655326563265732658326593266032661326623266332664326653266632667326683266932670326713267232673326743267532676326773267832679326803268132682326833268432685326863268732688326893269032691326923269332694326953269632697326983269932700327013270232703327043270532706327073270832709327103271132712327133271432715327163271732718327193272032721327223272332724327253272632727327283272932730327313273232733327343273532736327373273832739327403274132742327433274432745327463274732748327493275032751
  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. // Code generated from fast-path.go.tmpl - DO NOT EDIT.
  5. package codec
  6. // Fast path functions try to create a fast path encode or decode implementation
  7. // for common maps and slices.
  8. //
  9. // We define the functions and register then in this single file
  10. // so as not to pollute the encode.go and decode.go, and create a dependency in there.
  11. // This file can be omitted without causing a build failure.
  12. //
  13. // The advantage of fast paths is:
  14. // - Many calls bypass reflection altogether
  15. //
  16. // Currently support
  17. // - slice of all builtin types,
  18. // - map of all builtin types to string or interface value
  19. // - symmetrical maps of all builtin types (e.g. str-str, uint8-uint8)
  20. // This should provide adequate "typical" implementations.
  21. //
  22. // Note that fast track decode functions must handle values for which an address cannot be obtained.
  23. // For example:
  24. // m2 := map[string]int{}
  25. // p2 := []interface{}{m2}
  26. // // decoding into p2 will bomb if fast track functions do not treat like unaddressable.
  27. //
  28. import (
  29. "reflect"
  30. "sort"
  31. )
  32. const fastpathEnabled = true
  33. type fastpathT struct{}
  34. var fastpathTV fastpathT
  35. type fastpathE struct {
  36. rtid uintptr
  37. rt reflect.Type
  38. encfn func(*Encoder, *codecFnInfo, reflect.Value)
  39. decfn func(*Decoder, *codecFnInfo, reflect.Value)
  40. }
  41. type fastpathA [271]fastpathE
  42. func (x *fastpathA) index(rtid uintptr) int {
  43. // use binary search to grab the index (adapted from sort/search.go)
  44. h, i, j := 0, 0, 271 // len(x)
  45. for i < j {
  46. h = i + (j-i)/2
  47. if x[h].rtid < rtid {
  48. i = h + 1
  49. } else {
  50. j = h
  51. }
  52. }
  53. if i < 271 && x[i].rtid == rtid {
  54. return i
  55. }
  56. return -1
  57. }
  58. type fastpathAslice []fastpathE
  59. func (x fastpathAslice) Len() int { return len(x) }
  60. func (x fastpathAslice) Less(i, j int) bool { return x[i].rtid < x[j].rtid }
  61. func (x fastpathAslice) Swap(i, j int) { x[i], x[j] = x[j], x[i] }
  62. var fastpathAV fastpathA
  63. // due to possible initialization loop error, make fastpath in an init()
  64. func init() {
  65. i := 0
  66. fn := func(v interface{},
  67. fe func(*Encoder, *codecFnInfo, reflect.Value),
  68. fd func(*Decoder, *codecFnInfo, reflect.Value)) (f fastpathE) {
  69. xrt := reflect.TypeOf(v)
  70. xptr := rt2id(xrt)
  71. fastpathAV[i] = fastpathE{xptr, xrt, fe, fd}
  72. i++
  73. return
  74. }
  75. fn([]interface{}(nil), (*Encoder).fastpathEncSliceIntfR, (*Decoder).fastpathDecSliceIntfR)
  76. fn([]string(nil), (*Encoder).fastpathEncSliceStringR, (*Decoder).fastpathDecSliceStringR)
  77. fn([]float32(nil), (*Encoder).fastpathEncSliceFloat32R, (*Decoder).fastpathDecSliceFloat32R)
  78. fn([]float64(nil), (*Encoder).fastpathEncSliceFloat64R, (*Decoder).fastpathDecSliceFloat64R)
  79. fn([]uint(nil), (*Encoder).fastpathEncSliceUintR, (*Decoder).fastpathDecSliceUintR)
  80. fn([]uint16(nil), (*Encoder).fastpathEncSliceUint16R, (*Decoder).fastpathDecSliceUint16R)
  81. fn([]uint32(nil), (*Encoder).fastpathEncSliceUint32R, (*Decoder).fastpathDecSliceUint32R)
  82. fn([]uint64(nil), (*Encoder).fastpathEncSliceUint64R, (*Decoder).fastpathDecSliceUint64R)
  83. fn([]uintptr(nil), (*Encoder).fastpathEncSliceUintptrR, (*Decoder).fastpathDecSliceUintptrR)
  84. fn([]int(nil), (*Encoder).fastpathEncSliceIntR, (*Decoder).fastpathDecSliceIntR)
  85. fn([]int8(nil), (*Encoder).fastpathEncSliceInt8R, (*Decoder).fastpathDecSliceInt8R)
  86. fn([]int16(nil), (*Encoder).fastpathEncSliceInt16R, (*Decoder).fastpathDecSliceInt16R)
  87. fn([]int32(nil), (*Encoder).fastpathEncSliceInt32R, (*Decoder).fastpathDecSliceInt32R)
  88. fn([]int64(nil), (*Encoder).fastpathEncSliceInt64R, (*Decoder).fastpathDecSliceInt64R)
  89. fn([]bool(nil), (*Encoder).fastpathEncSliceBoolR, (*Decoder).fastpathDecSliceBoolR)
  90. fn(map[interface{}]interface{}(nil), (*Encoder).fastpathEncMapIntfIntfR, (*Decoder).fastpathDecMapIntfIntfR)
  91. fn(map[interface{}]string(nil), (*Encoder).fastpathEncMapIntfStringR, (*Decoder).fastpathDecMapIntfStringR)
  92. fn(map[interface{}]uint(nil), (*Encoder).fastpathEncMapIntfUintR, (*Decoder).fastpathDecMapIntfUintR)
  93. fn(map[interface{}]uint8(nil), (*Encoder).fastpathEncMapIntfUint8R, (*Decoder).fastpathDecMapIntfUint8R)
  94. fn(map[interface{}]uint16(nil), (*Encoder).fastpathEncMapIntfUint16R, (*Decoder).fastpathDecMapIntfUint16R)
  95. fn(map[interface{}]uint32(nil), (*Encoder).fastpathEncMapIntfUint32R, (*Decoder).fastpathDecMapIntfUint32R)
  96. fn(map[interface{}]uint64(nil), (*Encoder).fastpathEncMapIntfUint64R, (*Decoder).fastpathDecMapIntfUint64R)
  97. fn(map[interface{}]uintptr(nil), (*Encoder).fastpathEncMapIntfUintptrR, (*Decoder).fastpathDecMapIntfUintptrR)
  98. fn(map[interface{}]int(nil), (*Encoder).fastpathEncMapIntfIntR, (*Decoder).fastpathDecMapIntfIntR)
  99. fn(map[interface{}]int8(nil), (*Encoder).fastpathEncMapIntfInt8R, (*Decoder).fastpathDecMapIntfInt8R)
  100. fn(map[interface{}]int16(nil), (*Encoder).fastpathEncMapIntfInt16R, (*Decoder).fastpathDecMapIntfInt16R)
  101. fn(map[interface{}]int32(nil), (*Encoder).fastpathEncMapIntfInt32R, (*Decoder).fastpathDecMapIntfInt32R)
  102. fn(map[interface{}]int64(nil), (*Encoder).fastpathEncMapIntfInt64R, (*Decoder).fastpathDecMapIntfInt64R)
  103. fn(map[interface{}]float32(nil), (*Encoder).fastpathEncMapIntfFloat32R, (*Decoder).fastpathDecMapIntfFloat32R)
  104. fn(map[interface{}]float64(nil), (*Encoder).fastpathEncMapIntfFloat64R, (*Decoder).fastpathDecMapIntfFloat64R)
  105. fn(map[interface{}]bool(nil), (*Encoder).fastpathEncMapIntfBoolR, (*Decoder).fastpathDecMapIntfBoolR)
  106. fn(map[string]interface{}(nil), (*Encoder).fastpathEncMapStringIntfR, (*Decoder).fastpathDecMapStringIntfR)
  107. fn(map[string]string(nil), (*Encoder).fastpathEncMapStringStringR, (*Decoder).fastpathDecMapStringStringR)
  108. fn(map[string]uint(nil), (*Encoder).fastpathEncMapStringUintR, (*Decoder).fastpathDecMapStringUintR)
  109. fn(map[string]uint8(nil), (*Encoder).fastpathEncMapStringUint8R, (*Decoder).fastpathDecMapStringUint8R)
  110. fn(map[string]uint16(nil), (*Encoder).fastpathEncMapStringUint16R, (*Decoder).fastpathDecMapStringUint16R)
  111. fn(map[string]uint32(nil), (*Encoder).fastpathEncMapStringUint32R, (*Decoder).fastpathDecMapStringUint32R)
  112. fn(map[string]uint64(nil), (*Encoder).fastpathEncMapStringUint64R, (*Decoder).fastpathDecMapStringUint64R)
  113. fn(map[string]uintptr(nil), (*Encoder).fastpathEncMapStringUintptrR, (*Decoder).fastpathDecMapStringUintptrR)
  114. fn(map[string]int(nil), (*Encoder).fastpathEncMapStringIntR, (*Decoder).fastpathDecMapStringIntR)
  115. fn(map[string]int8(nil), (*Encoder).fastpathEncMapStringInt8R, (*Decoder).fastpathDecMapStringInt8R)
  116. fn(map[string]int16(nil), (*Encoder).fastpathEncMapStringInt16R, (*Decoder).fastpathDecMapStringInt16R)
  117. fn(map[string]int32(nil), (*Encoder).fastpathEncMapStringInt32R, (*Decoder).fastpathDecMapStringInt32R)
  118. fn(map[string]int64(nil), (*Encoder).fastpathEncMapStringInt64R, (*Decoder).fastpathDecMapStringInt64R)
  119. fn(map[string]float32(nil), (*Encoder).fastpathEncMapStringFloat32R, (*Decoder).fastpathDecMapStringFloat32R)
  120. fn(map[string]float64(nil), (*Encoder).fastpathEncMapStringFloat64R, (*Decoder).fastpathDecMapStringFloat64R)
  121. fn(map[string]bool(nil), (*Encoder).fastpathEncMapStringBoolR, (*Decoder).fastpathDecMapStringBoolR)
  122. fn(map[float32]interface{}(nil), (*Encoder).fastpathEncMapFloat32IntfR, (*Decoder).fastpathDecMapFloat32IntfR)
  123. fn(map[float32]string(nil), (*Encoder).fastpathEncMapFloat32StringR, (*Decoder).fastpathDecMapFloat32StringR)
  124. fn(map[float32]uint(nil), (*Encoder).fastpathEncMapFloat32UintR, (*Decoder).fastpathDecMapFloat32UintR)
  125. fn(map[float32]uint8(nil), (*Encoder).fastpathEncMapFloat32Uint8R, (*Decoder).fastpathDecMapFloat32Uint8R)
  126. fn(map[float32]uint16(nil), (*Encoder).fastpathEncMapFloat32Uint16R, (*Decoder).fastpathDecMapFloat32Uint16R)
  127. fn(map[float32]uint32(nil), (*Encoder).fastpathEncMapFloat32Uint32R, (*Decoder).fastpathDecMapFloat32Uint32R)
  128. fn(map[float32]uint64(nil), (*Encoder).fastpathEncMapFloat32Uint64R, (*Decoder).fastpathDecMapFloat32Uint64R)
  129. fn(map[float32]uintptr(nil), (*Encoder).fastpathEncMapFloat32UintptrR, (*Decoder).fastpathDecMapFloat32UintptrR)
  130. fn(map[float32]int(nil), (*Encoder).fastpathEncMapFloat32IntR, (*Decoder).fastpathDecMapFloat32IntR)
  131. fn(map[float32]int8(nil), (*Encoder).fastpathEncMapFloat32Int8R, (*Decoder).fastpathDecMapFloat32Int8R)
  132. fn(map[float32]int16(nil), (*Encoder).fastpathEncMapFloat32Int16R, (*Decoder).fastpathDecMapFloat32Int16R)
  133. fn(map[float32]int32(nil), (*Encoder).fastpathEncMapFloat32Int32R, (*Decoder).fastpathDecMapFloat32Int32R)
  134. fn(map[float32]int64(nil), (*Encoder).fastpathEncMapFloat32Int64R, (*Decoder).fastpathDecMapFloat32Int64R)
  135. fn(map[float32]float32(nil), (*Encoder).fastpathEncMapFloat32Float32R, (*Decoder).fastpathDecMapFloat32Float32R)
  136. fn(map[float32]float64(nil), (*Encoder).fastpathEncMapFloat32Float64R, (*Decoder).fastpathDecMapFloat32Float64R)
  137. fn(map[float32]bool(nil), (*Encoder).fastpathEncMapFloat32BoolR, (*Decoder).fastpathDecMapFloat32BoolR)
  138. fn(map[float64]interface{}(nil), (*Encoder).fastpathEncMapFloat64IntfR, (*Decoder).fastpathDecMapFloat64IntfR)
  139. fn(map[float64]string(nil), (*Encoder).fastpathEncMapFloat64StringR, (*Decoder).fastpathDecMapFloat64StringR)
  140. fn(map[float64]uint(nil), (*Encoder).fastpathEncMapFloat64UintR, (*Decoder).fastpathDecMapFloat64UintR)
  141. fn(map[float64]uint8(nil), (*Encoder).fastpathEncMapFloat64Uint8R, (*Decoder).fastpathDecMapFloat64Uint8R)
  142. fn(map[float64]uint16(nil), (*Encoder).fastpathEncMapFloat64Uint16R, (*Decoder).fastpathDecMapFloat64Uint16R)
  143. fn(map[float64]uint32(nil), (*Encoder).fastpathEncMapFloat64Uint32R, (*Decoder).fastpathDecMapFloat64Uint32R)
  144. fn(map[float64]uint64(nil), (*Encoder).fastpathEncMapFloat64Uint64R, (*Decoder).fastpathDecMapFloat64Uint64R)
  145. fn(map[float64]uintptr(nil), (*Encoder).fastpathEncMapFloat64UintptrR, (*Decoder).fastpathDecMapFloat64UintptrR)
  146. fn(map[float64]int(nil), (*Encoder).fastpathEncMapFloat64IntR, (*Decoder).fastpathDecMapFloat64IntR)
  147. fn(map[float64]int8(nil), (*Encoder).fastpathEncMapFloat64Int8R, (*Decoder).fastpathDecMapFloat64Int8R)
  148. fn(map[float64]int16(nil), (*Encoder).fastpathEncMapFloat64Int16R, (*Decoder).fastpathDecMapFloat64Int16R)
  149. fn(map[float64]int32(nil), (*Encoder).fastpathEncMapFloat64Int32R, (*Decoder).fastpathDecMapFloat64Int32R)
  150. fn(map[float64]int64(nil), (*Encoder).fastpathEncMapFloat64Int64R, (*Decoder).fastpathDecMapFloat64Int64R)
  151. fn(map[float64]float32(nil), (*Encoder).fastpathEncMapFloat64Float32R, (*Decoder).fastpathDecMapFloat64Float32R)
  152. fn(map[float64]float64(nil), (*Encoder).fastpathEncMapFloat64Float64R, (*Decoder).fastpathDecMapFloat64Float64R)
  153. fn(map[float64]bool(nil), (*Encoder).fastpathEncMapFloat64BoolR, (*Decoder).fastpathDecMapFloat64BoolR)
  154. fn(map[uint]interface{}(nil), (*Encoder).fastpathEncMapUintIntfR, (*Decoder).fastpathDecMapUintIntfR)
  155. fn(map[uint]string(nil), (*Encoder).fastpathEncMapUintStringR, (*Decoder).fastpathDecMapUintStringR)
  156. fn(map[uint]uint(nil), (*Encoder).fastpathEncMapUintUintR, (*Decoder).fastpathDecMapUintUintR)
  157. fn(map[uint]uint8(nil), (*Encoder).fastpathEncMapUintUint8R, (*Decoder).fastpathDecMapUintUint8R)
  158. fn(map[uint]uint16(nil), (*Encoder).fastpathEncMapUintUint16R, (*Decoder).fastpathDecMapUintUint16R)
  159. fn(map[uint]uint32(nil), (*Encoder).fastpathEncMapUintUint32R, (*Decoder).fastpathDecMapUintUint32R)
  160. fn(map[uint]uint64(nil), (*Encoder).fastpathEncMapUintUint64R, (*Decoder).fastpathDecMapUintUint64R)
  161. fn(map[uint]uintptr(nil), (*Encoder).fastpathEncMapUintUintptrR, (*Decoder).fastpathDecMapUintUintptrR)
  162. fn(map[uint]int(nil), (*Encoder).fastpathEncMapUintIntR, (*Decoder).fastpathDecMapUintIntR)
  163. fn(map[uint]int8(nil), (*Encoder).fastpathEncMapUintInt8R, (*Decoder).fastpathDecMapUintInt8R)
  164. fn(map[uint]int16(nil), (*Encoder).fastpathEncMapUintInt16R, (*Decoder).fastpathDecMapUintInt16R)
  165. fn(map[uint]int32(nil), (*Encoder).fastpathEncMapUintInt32R, (*Decoder).fastpathDecMapUintInt32R)
  166. fn(map[uint]int64(nil), (*Encoder).fastpathEncMapUintInt64R, (*Decoder).fastpathDecMapUintInt64R)
  167. fn(map[uint]float32(nil), (*Encoder).fastpathEncMapUintFloat32R, (*Decoder).fastpathDecMapUintFloat32R)
  168. fn(map[uint]float64(nil), (*Encoder).fastpathEncMapUintFloat64R, (*Decoder).fastpathDecMapUintFloat64R)
  169. fn(map[uint]bool(nil), (*Encoder).fastpathEncMapUintBoolR, (*Decoder).fastpathDecMapUintBoolR)
  170. fn(map[uint8]interface{}(nil), (*Encoder).fastpathEncMapUint8IntfR, (*Decoder).fastpathDecMapUint8IntfR)
  171. fn(map[uint8]string(nil), (*Encoder).fastpathEncMapUint8StringR, (*Decoder).fastpathDecMapUint8StringR)
  172. fn(map[uint8]uint(nil), (*Encoder).fastpathEncMapUint8UintR, (*Decoder).fastpathDecMapUint8UintR)
  173. fn(map[uint8]uint8(nil), (*Encoder).fastpathEncMapUint8Uint8R, (*Decoder).fastpathDecMapUint8Uint8R)
  174. fn(map[uint8]uint16(nil), (*Encoder).fastpathEncMapUint8Uint16R, (*Decoder).fastpathDecMapUint8Uint16R)
  175. fn(map[uint8]uint32(nil), (*Encoder).fastpathEncMapUint8Uint32R, (*Decoder).fastpathDecMapUint8Uint32R)
  176. fn(map[uint8]uint64(nil), (*Encoder).fastpathEncMapUint8Uint64R, (*Decoder).fastpathDecMapUint8Uint64R)
  177. fn(map[uint8]uintptr(nil), (*Encoder).fastpathEncMapUint8UintptrR, (*Decoder).fastpathDecMapUint8UintptrR)
  178. fn(map[uint8]int(nil), (*Encoder).fastpathEncMapUint8IntR, (*Decoder).fastpathDecMapUint8IntR)
  179. fn(map[uint8]int8(nil), (*Encoder).fastpathEncMapUint8Int8R, (*Decoder).fastpathDecMapUint8Int8R)
  180. fn(map[uint8]int16(nil), (*Encoder).fastpathEncMapUint8Int16R, (*Decoder).fastpathDecMapUint8Int16R)
  181. fn(map[uint8]int32(nil), (*Encoder).fastpathEncMapUint8Int32R, (*Decoder).fastpathDecMapUint8Int32R)
  182. fn(map[uint8]int64(nil), (*Encoder).fastpathEncMapUint8Int64R, (*Decoder).fastpathDecMapUint8Int64R)
  183. fn(map[uint8]float32(nil), (*Encoder).fastpathEncMapUint8Float32R, (*Decoder).fastpathDecMapUint8Float32R)
  184. fn(map[uint8]float64(nil), (*Encoder).fastpathEncMapUint8Float64R, (*Decoder).fastpathDecMapUint8Float64R)
  185. fn(map[uint8]bool(nil), (*Encoder).fastpathEncMapUint8BoolR, (*Decoder).fastpathDecMapUint8BoolR)
  186. fn(map[uint16]interface{}(nil), (*Encoder).fastpathEncMapUint16IntfR, (*Decoder).fastpathDecMapUint16IntfR)
  187. fn(map[uint16]string(nil), (*Encoder).fastpathEncMapUint16StringR, (*Decoder).fastpathDecMapUint16StringR)
  188. fn(map[uint16]uint(nil), (*Encoder).fastpathEncMapUint16UintR, (*Decoder).fastpathDecMapUint16UintR)
  189. fn(map[uint16]uint8(nil), (*Encoder).fastpathEncMapUint16Uint8R, (*Decoder).fastpathDecMapUint16Uint8R)
  190. fn(map[uint16]uint16(nil), (*Encoder).fastpathEncMapUint16Uint16R, (*Decoder).fastpathDecMapUint16Uint16R)
  191. fn(map[uint16]uint32(nil), (*Encoder).fastpathEncMapUint16Uint32R, (*Decoder).fastpathDecMapUint16Uint32R)
  192. fn(map[uint16]uint64(nil), (*Encoder).fastpathEncMapUint16Uint64R, (*Decoder).fastpathDecMapUint16Uint64R)
  193. fn(map[uint16]uintptr(nil), (*Encoder).fastpathEncMapUint16UintptrR, (*Decoder).fastpathDecMapUint16UintptrR)
  194. fn(map[uint16]int(nil), (*Encoder).fastpathEncMapUint16IntR, (*Decoder).fastpathDecMapUint16IntR)
  195. fn(map[uint16]int8(nil), (*Encoder).fastpathEncMapUint16Int8R, (*Decoder).fastpathDecMapUint16Int8R)
  196. fn(map[uint16]int16(nil), (*Encoder).fastpathEncMapUint16Int16R, (*Decoder).fastpathDecMapUint16Int16R)
  197. fn(map[uint16]int32(nil), (*Encoder).fastpathEncMapUint16Int32R, (*Decoder).fastpathDecMapUint16Int32R)
  198. fn(map[uint16]int64(nil), (*Encoder).fastpathEncMapUint16Int64R, (*Decoder).fastpathDecMapUint16Int64R)
  199. fn(map[uint16]float32(nil), (*Encoder).fastpathEncMapUint16Float32R, (*Decoder).fastpathDecMapUint16Float32R)
  200. fn(map[uint16]float64(nil), (*Encoder).fastpathEncMapUint16Float64R, (*Decoder).fastpathDecMapUint16Float64R)
  201. fn(map[uint16]bool(nil), (*Encoder).fastpathEncMapUint16BoolR, (*Decoder).fastpathDecMapUint16BoolR)
  202. fn(map[uint32]interface{}(nil), (*Encoder).fastpathEncMapUint32IntfR, (*Decoder).fastpathDecMapUint32IntfR)
  203. fn(map[uint32]string(nil), (*Encoder).fastpathEncMapUint32StringR, (*Decoder).fastpathDecMapUint32StringR)
  204. fn(map[uint32]uint(nil), (*Encoder).fastpathEncMapUint32UintR, (*Decoder).fastpathDecMapUint32UintR)
  205. fn(map[uint32]uint8(nil), (*Encoder).fastpathEncMapUint32Uint8R, (*Decoder).fastpathDecMapUint32Uint8R)
  206. fn(map[uint32]uint16(nil), (*Encoder).fastpathEncMapUint32Uint16R, (*Decoder).fastpathDecMapUint32Uint16R)
  207. fn(map[uint32]uint32(nil), (*Encoder).fastpathEncMapUint32Uint32R, (*Decoder).fastpathDecMapUint32Uint32R)
  208. fn(map[uint32]uint64(nil), (*Encoder).fastpathEncMapUint32Uint64R, (*Decoder).fastpathDecMapUint32Uint64R)
  209. fn(map[uint32]uintptr(nil), (*Encoder).fastpathEncMapUint32UintptrR, (*Decoder).fastpathDecMapUint32UintptrR)
  210. fn(map[uint32]int(nil), (*Encoder).fastpathEncMapUint32IntR, (*Decoder).fastpathDecMapUint32IntR)
  211. fn(map[uint32]int8(nil), (*Encoder).fastpathEncMapUint32Int8R, (*Decoder).fastpathDecMapUint32Int8R)
  212. fn(map[uint32]int16(nil), (*Encoder).fastpathEncMapUint32Int16R, (*Decoder).fastpathDecMapUint32Int16R)
  213. fn(map[uint32]int32(nil), (*Encoder).fastpathEncMapUint32Int32R, (*Decoder).fastpathDecMapUint32Int32R)
  214. fn(map[uint32]int64(nil), (*Encoder).fastpathEncMapUint32Int64R, (*Decoder).fastpathDecMapUint32Int64R)
  215. fn(map[uint32]float32(nil), (*Encoder).fastpathEncMapUint32Float32R, (*Decoder).fastpathDecMapUint32Float32R)
  216. fn(map[uint32]float64(nil), (*Encoder).fastpathEncMapUint32Float64R, (*Decoder).fastpathDecMapUint32Float64R)
  217. fn(map[uint32]bool(nil), (*Encoder).fastpathEncMapUint32BoolR, (*Decoder).fastpathDecMapUint32BoolR)
  218. fn(map[uint64]interface{}(nil), (*Encoder).fastpathEncMapUint64IntfR, (*Decoder).fastpathDecMapUint64IntfR)
  219. fn(map[uint64]string(nil), (*Encoder).fastpathEncMapUint64StringR, (*Decoder).fastpathDecMapUint64StringR)
  220. fn(map[uint64]uint(nil), (*Encoder).fastpathEncMapUint64UintR, (*Decoder).fastpathDecMapUint64UintR)
  221. fn(map[uint64]uint8(nil), (*Encoder).fastpathEncMapUint64Uint8R, (*Decoder).fastpathDecMapUint64Uint8R)
  222. fn(map[uint64]uint16(nil), (*Encoder).fastpathEncMapUint64Uint16R, (*Decoder).fastpathDecMapUint64Uint16R)
  223. fn(map[uint64]uint32(nil), (*Encoder).fastpathEncMapUint64Uint32R, (*Decoder).fastpathDecMapUint64Uint32R)
  224. fn(map[uint64]uint64(nil), (*Encoder).fastpathEncMapUint64Uint64R, (*Decoder).fastpathDecMapUint64Uint64R)
  225. fn(map[uint64]uintptr(nil), (*Encoder).fastpathEncMapUint64UintptrR, (*Decoder).fastpathDecMapUint64UintptrR)
  226. fn(map[uint64]int(nil), (*Encoder).fastpathEncMapUint64IntR, (*Decoder).fastpathDecMapUint64IntR)
  227. fn(map[uint64]int8(nil), (*Encoder).fastpathEncMapUint64Int8R, (*Decoder).fastpathDecMapUint64Int8R)
  228. fn(map[uint64]int16(nil), (*Encoder).fastpathEncMapUint64Int16R, (*Decoder).fastpathDecMapUint64Int16R)
  229. fn(map[uint64]int32(nil), (*Encoder).fastpathEncMapUint64Int32R, (*Decoder).fastpathDecMapUint64Int32R)
  230. fn(map[uint64]int64(nil), (*Encoder).fastpathEncMapUint64Int64R, (*Decoder).fastpathDecMapUint64Int64R)
  231. fn(map[uint64]float32(nil), (*Encoder).fastpathEncMapUint64Float32R, (*Decoder).fastpathDecMapUint64Float32R)
  232. fn(map[uint64]float64(nil), (*Encoder).fastpathEncMapUint64Float64R, (*Decoder).fastpathDecMapUint64Float64R)
  233. fn(map[uint64]bool(nil), (*Encoder).fastpathEncMapUint64BoolR, (*Decoder).fastpathDecMapUint64BoolR)
  234. fn(map[uintptr]interface{}(nil), (*Encoder).fastpathEncMapUintptrIntfR, (*Decoder).fastpathDecMapUintptrIntfR)
  235. fn(map[uintptr]string(nil), (*Encoder).fastpathEncMapUintptrStringR, (*Decoder).fastpathDecMapUintptrStringR)
  236. fn(map[uintptr]uint(nil), (*Encoder).fastpathEncMapUintptrUintR, (*Decoder).fastpathDecMapUintptrUintR)
  237. fn(map[uintptr]uint8(nil), (*Encoder).fastpathEncMapUintptrUint8R, (*Decoder).fastpathDecMapUintptrUint8R)
  238. fn(map[uintptr]uint16(nil), (*Encoder).fastpathEncMapUintptrUint16R, (*Decoder).fastpathDecMapUintptrUint16R)
  239. fn(map[uintptr]uint32(nil), (*Encoder).fastpathEncMapUintptrUint32R, (*Decoder).fastpathDecMapUintptrUint32R)
  240. fn(map[uintptr]uint64(nil), (*Encoder).fastpathEncMapUintptrUint64R, (*Decoder).fastpathDecMapUintptrUint64R)
  241. fn(map[uintptr]uintptr(nil), (*Encoder).fastpathEncMapUintptrUintptrR, (*Decoder).fastpathDecMapUintptrUintptrR)
  242. fn(map[uintptr]int(nil), (*Encoder).fastpathEncMapUintptrIntR, (*Decoder).fastpathDecMapUintptrIntR)
  243. fn(map[uintptr]int8(nil), (*Encoder).fastpathEncMapUintptrInt8R, (*Decoder).fastpathDecMapUintptrInt8R)
  244. fn(map[uintptr]int16(nil), (*Encoder).fastpathEncMapUintptrInt16R, (*Decoder).fastpathDecMapUintptrInt16R)
  245. fn(map[uintptr]int32(nil), (*Encoder).fastpathEncMapUintptrInt32R, (*Decoder).fastpathDecMapUintptrInt32R)
  246. fn(map[uintptr]int64(nil), (*Encoder).fastpathEncMapUintptrInt64R, (*Decoder).fastpathDecMapUintptrInt64R)
  247. fn(map[uintptr]float32(nil), (*Encoder).fastpathEncMapUintptrFloat32R, (*Decoder).fastpathDecMapUintptrFloat32R)
  248. fn(map[uintptr]float64(nil), (*Encoder).fastpathEncMapUintptrFloat64R, (*Decoder).fastpathDecMapUintptrFloat64R)
  249. fn(map[uintptr]bool(nil), (*Encoder).fastpathEncMapUintptrBoolR, (*Decoder).fastpathDecMapUintptrBoolR)
  250. fn(map[int]interface{}(nil), (*Encoder).fastpathEncMapIntIntfR, (*Decoder).fastpathDecMapIntIntfR)
  251. fn(map[int]string(nil), (*Encoder).fastpathEncMapIntStringR, (*Decoder).fastpathDecMapIntStringR)
  252. fn(map[int]uint(nil), (*Encoder).fastpathEncMapIntUintR, (*Decoder).fastpathDecMapIntUintR)
  253. fn(map[int]uint8(nil), (*Encoder).fastpathEncMapIntUint8R, (*Decoder).fastpathDecMapIntUint8R)
  254. fn(map[int]uint16(nil), (*Encoder).fastpathEncMapIntUint16R, (*Decoder).fastpathDecMapIntUint16R)
  255. fn(map[int]uint32(nil), (*Encoder).fastpathEncMapIntUint32R, (*Decoder).fastpathDecMapIntUint32R)
  256. fn(map[int]uint64(nil), (*Encoder).fastpathEncMapIntUint64R, (*Decoder).fastpathDecMapIntUint64R)
  257. fn(map[int]uintptr(nil), (*Encoder).fastpathEncMapIntUintptrR, (*Decoder).fastpathDecMapIntUintptrR)
  258. fn(map[int]int(nil), (*Encoder).fastpathEncMapIntIntR, (*Decoder).fastpathDecMapIntIntR)
  259. fn(map[int]int8(nil), (*Encoder).fastpathEncMapIntInt8R, (*Decoder).fastpathDecMapIntInt8R)
  260. fn(map[int]int16(nil), (*Encoder).fastpathEncMapIntInt16R, (*Decoder).fastpathDecMapIntInt16R)
  261. fn(map[int]int32(nil), (*Encoder).fastpathEncMapIntInt32R, (*Decoder).fastpathDecMapIntInt32R)
  262. fn(map[int]int64(nil), (*Encoder).fastpathEncMapIntInt64R, (*Decoder).fastpathDecMapIntInt64R)
  263. fn(map[int]float32(nil), (*Encoder).fastpathEncMapIntFloat32R, (*Decoder).fastpathDecMapIntFloat32R)
  264. fn(map[int]float64(nil), (*Encoder).fastpathEncMapIntFloat64R, (*Decoder).fastpathDecMapIntFloat64R)
  265. fn(map[int]bool(nil), (*Encoder).fastpathEncMapIntBoolR, (*Decoder).fastpathDecMapIntBoolR)
  266. fn(map[int8]interface{}(nil), (*Encoder).fastpathEncMapInt8IntfR, (*Decoder).fastpathDecMapInt8IntfR)
  267. fn(map[int8]string(nil), (*Encoder).fastpathEncMapInt8StringR, (*Decoder).fastpathDecMapInt8StringR)
  268. fn(map[int8]uint(nil), (*Encoder).fastpathEncMapInt8UintR, (*Decoder).fastpathDecMapInt8UintR)
  269. fn(map[int8]uint8(nil), (*Encoder).fastpathEncMapInt8Uint8R, (*Decoder).fastpathDecMapInt8Uint8R)
  270. fn(map[int8]uint16(nil), (*Encoder).fastpathEncMapInt8Uint16R, (*Decoder).fastpathDecMapInt8Uint16R)
  271. fn(map[int8]uint32(nil), (*Encoder).fastpathEncMapInt8Uint32R, (*Decoder).fastpathDecMapInt8Uint32R)
  272. fn(map[int8]uint64(nil), (*Encoder).fastpathEncMapInt8Uint64R, (*Decoder).fastpathDecMapInt8Uint64R)
  273. fn(map[int8]uintptr(nil), (*Encoder).fastpathEncMapInt8UintptrR, (*Decoder).fastpathDecMapInt8UintptrR)
  274. fn(map[int8]int(nil), (*Encoder).fastpathEncMapInt8IntR, (*Decoder).fastpathDecMapInt8IntR)
  275. fn(map[int8]int8(nil), (*Encoder).fastpathEncMapInt8Int8R, (*Decoder).fastpathDecMapInt8Int8R)
  276. fn(map[int8]int16(nil), (*Encoder).fastpathEncMapInt8Int16R, (*Decoder).fastpathDecMapInt8Int16R)
  277. fn(map[int8]int32(nil), (*Encoder).fastpathEncMapInt8Int32R, (*Decoder).fastpathDecMapInt8Int32R)
  278. fn(map[int8]int64(nil), (*Encoder).fastpathEncMapInt8Int64R, (*Decoder).fastpathDecMapInt8Int64R)
  279. fn(map[int8]float32(nil), (*Encoder).fastpathEncMapInt8Float32R, (*Decoder).fastpathDecMapInt8Float32R)
  280. fn(map[int8]float64(nil), (*Encoder).fastpathEncMapInt8Float64R, (*Decoder).fastpathDecMapInt8Float64R)
  281. fn(map[int8]bool(nil), (*Encoder).fastpathEncMapInt8BoolR, (*Decoder).fastpathDecMapInt8BoolR)
  282. fn(map[int16]interface{}(nil), (*Encoder).fastpathEncMapInt16IntfR, (*Decoder).fastpathDecMapInt16IntfR)
  283. fn(map[int16]string(nil), (*Encoder).fastpathEncMapInt16StringR, (*Decoder).fastpathDecMapInt16StringR)
  284. fn(map[int16]uint(nil), (*Encoder).fastpathEncMapInt16UintR, (*Decoder).fastpathDecMapInt16UintR)
  285. fn(map[int16]uint8(nil), (*Encoder).fastpathEncMapInt16Uint8R, (*Decoder).fastpathDecMapInt16Uint8R)
  286. fn(map[int16]uint16(nil), (*Encoder).fastpathEncMapInt16Uint16R, (*Decoder).fastpathDecMapInt16Uint16R)
  287. fn(map[int16]uint32(nil), (*Encoder).fastpathEncMapInt16Uint32R, (*Decoder).fastpathDecMapInt16Uint32R)
  288. fn(map[int16]uint64(nil), (*Encoder).fastpathEncMapInt16Uint64R, (*Decoder).fastpathDecMapInt16Uint64R)
  289. fn(map[int16]uintptr(nil), (*Encoder).fastpathEncMapInt16UintptrR, (*Decoder).fastpathDecMapInt16UintptrR)
  290. fn(map[int16]int(nil), (*Encoder).fastpathEncMapInt16IntR, (*Decoder).fastpathDecMapInt16IntR)
  291. fn(map[int16]int8(nil), (*Encoder).fastpathEncMapInt16Int8R, (*Decoder).fastpathDecMapInt16Int8R)
  292. fn(map[int16]int16(nil), (*Encoder).fastpathEncMapInt16Int16R, (*Decoder).fastpathDecMapInt16Int16R)
  293. fn(map[int16]int32(nil), (*Encoder).fastpathEncMapInt16Int32R, (*Decoder).fastpathDecMapInt16Int32R)
  294. fn(map[int16]int64(nil), (*Encoder).fastpathEncMapInt16Int64R, (*Decoder).fastpathDecMapInt16Int64R)
  295. fn(map[int16]float32(nil), (*Encoder).fastpathEncMapInt16Float32R, (*Decoder).fastpathDecMapInt16Float32R)
  296. fn(map[int16]float64(nil), (*Encoder).fastpathEncMapInt16Float64R, (*Decoder).fastpathDecMapInt16Float64R)
  297. fn(map[int16]bool(nil), (*Encoder).fastpathEncMapInt16BoolR, (*Decoder).fastpathDecMapInt16BoolR)
  298. fn(map[int32]interface{}(nil), (*Encoder).fastpathEncMapInt32IntfR, (*Decoder).fastpathDecMapInt32IntfR)
  299. fn(map[int32]string(nil), (*Encoder).fastpathEncMapInt32StringR, (*Decoder).fastpathDecMapInt32StringR)
  300. fn(map[int32]uint(nil), (*Encoder).fastpathEncMapInt32UintR, (*Decoder).fastpathDecMapInt32UintR)
  301. fn(map[int32]uint8(nil), (*Encoder).fastpathEncMapInt32Uint8R, (*Decoder).fastpathDecMapInt32Uint8R)
  302. fn(map[int32]uint16(nil), (*Encoder).fastpathEncMapInt32Uint16R, (*Decoder).fastpathDecMapInt32Uint16R)
  303. fn(map[int32]uint32(nil), (*Encoder).fastpathEncMapInt32Uint32R, (*Decoder).fastpathDecMapInt32Uint32R)
  304. fn(map[int32]uint64(nil), (*Encoder).fastpathEncMapInt32Uint64R, (*Decoder).fastpathDecMapInt32Uint64R)
  305. fn(map[int32]uintptr(nil), (*Encoder).fastpathEncMapInt32UintptrR, (*Decoder).fastpathDecMapInt32UintptrR)
  306. fn(map[int32]int(nil), (*Encoder).fastpathEncMapInt32IntR, (*Decoder).fastpathDecMapInt32IntR)
  307. fn(map[int32]int8(nil), (*Encoder).fastpathEncMapInt32Int8R, (*Decoder).fastpathDecMapInt32Int8R)
  308. fn(map[int32]int16(nil), (*Encoder).fastpathEncMapInt32Int16R, (*Decoder).fastpathDecMapInt32Int16R)
  309. fn(map[int32]int32(nil), (*Encoder).fastpathEncMapInt32Int32R, (*Decoder).fastpathDecMapInt32Int32R)
  310. fn(map[int32]int64(nil), (*Encoder).fastpathEncMapInt32Int64R, (*Decoder).fastpathDecMapInt32Int64R)
  311. fn(map[int32]float32(nil), (*Encoder).fastpathEncMapInt32Float32R, (*Decoder).fastpathDecMapInt32Float32R)
  312. fn(map[int32]float64(nil), (*Encoder).fastpathEncMapInt32Float64R, (*Decoder).fastpathDecMapInt32Float64R)
  313. fn(map[int32]bool(nil), (*Encoder).fastpathEncMapInt32BoolR, (*Decoder).fastpathDecMapInt32BoolR)
  314. fn(map[int64]interface{}(nil), (*Encoder).fastpathEncMapInt64IntfR, (*Decoder).fastpathDecMapInt64IntfR)
  315. fn(map[int64]string(nil), (*Encoder).fastpathEncMapInt64StringR, (*Decoder).fastpathDecMapInt64StringR)
  316. fn(map[int64]uint(nil), (*Encoder).fastpathEncMapInt64UintR, (*Decoder).fastpathDecMapInt64UintR)
  317. fn(map[int64]uint8(nil), (*Encoder).fastpathEncMapInt64Uint8R, (*Decoder).fastpathDecMapInt64Uint8R)
  318. fn(map[int64]uint16(nil), (*Encoder).fastpathEncMapInt64Uint16R, (*Decoder).fastpathDecMapInt64Uint16R)
  319. fn(map[int64]uint32(nil), (*Encoder).fastpathEncMapInt64Uint32R, (*Decoder).fastpathDecMapInt64Uint32R)
  320. fn(map[int64]uint64(nil), (*Encoder).fastpathEncMapInt64Uint64R, (*Decoder).fastpathDecMapInt64Uint64R)
  321. fn(map[int64]uintptr(nil), (*Encoder).fastpathEncMapInt64UintptrR, (*Decoder).fastpathDecMapInt64UintptrR)
  322. fn(map[int64]int(nil), (*Encoder).fastpathEncMapInt64IntR, (*Decoder).fastpathDecMapInt64IntR)
  323. fn(map[int64]int8(nil), (*Encoder).fastpathEncMapInt64Int8R, (*Decoder).fastpathDecMapInt64Int8R)
  324. fn(map[int64]int16(nil), (*Encoder).fastpathEncMapInt64Int16R, (*Decoder).fastpathDecMapInt64Int16R)
  325. fn(map[int64]int32(nil), (*Encoder).fastpathEncMapInt64Int32R, (*Decoder).fastpathDecMapInt64Int32R)
  326. fn(map[int64]int64(nil), (*Encoder).fastpathEncMapInt64Int64R, (*Decoder).fastpathDecMapInt64Int64R)
  327. fn(map[int64]float32(nil), (*Encoder).fastpathEncMapInt64Float32R, (*Decoder).fastpathDecMapInt64Float32R)
  328. fn(map[int64]float64(nil), (*Encoder).fastpathEncMapInt64Float64R, (*Decoder).fastpathDecMapInt64Float64R)
  329. fn(map[int64]bool(nil), (*Encoder).fastpathEncMapInt64BoolR, (*Decoder).fastpathDecMapInt64BoolR)
  330. fn(map[bool]interface{}(nil), (*Encoder).fastpathEncMapBoolIntfR, (*Decoder).fastpathDecMapBoolIntfR)
  331. fn(map[bool]string(nil), (*Encoder).fastpathEncMapBoolStringR, (*Decoder).fastpathDecMapBoolStringR)
  332. fn(map[bool]uint(nil), (*Encoder).fastpathEncMapBoolUintR, (*Decoder).fastpathDecMapBoolUintR)
  333. fn(map[bool]uint8(nil), (*Encoder).fastpathEncMapBoolUint8R, (*Decoder).fastpathDecMapBoolUint8R)
  334. fn(map[bool]uint16(nil), (*Encoder).fastpathEncMapBoolUint16R, (*Decoder).fastpathDecMapBoolUint16R)
  335. fn(map[bool]uint32(nil), (*Encoder).fastpathEncMapBoolUint32R, (*Decoder).fastpathDecMapBoolUint32R)
  336. fn(map[bool]uint64(nil), (*Encoder).fastpathEncMapBoolUint64R, (*Decoder).fastpathDecMapBoolUint64R)
  337. fn(map[bool]uintptr(nil), (*Encoder).fastpathEncMapBoolUintptrR, (*Decoder).fastpathDecMapBoolUintptrR)
  338. fn(map[bool]int(nil), (*Encoder).fastpathEncMapBoolIntR, (*Decoder).fastpathDecMapBoolIntR)
  339. fn(map[bool]int8(nil), (*Encoder).fastpathEncMapBoolInt8R, (*Decoder).fastpathDecMapBoolInt8R)
  340. fn(map[bool]int16(nil), (*Encoder).fastpathEncMapBoolInt16R, (*Decoder).fastpathDecMapBoolInt16R)
  341. fn(map[bool]int32(nil), (*Encoder).fastpathEncMapBoolInt32R, (*Decoder).fastpathDecMapBoolInt32R)
  342. fn(map[bool]int64(nil), (*Encoder).fastpathEncMapBoolInt64R, (*Decoder).fastpathDecMapBoolInt64R)
  343. fn(map[bool]float32(nil), (*Encoder).fastpathEncMapBoolFloat32R, (*Decoder).fastpathDecMapBoolFloat32R)
  344. fn(map[bool]float64(nil), (*Encoder).fastpathEncMapBoolFloat64R, (*Decoder).fastpathDecMapBoolFloat64R)
  345. fn(map[bool]bool(nil), (*Encoder).fastpathEncMapBoolBoolR, (*Decoder).fastpathDecMapBoolBoolR)
  346. sort.Sort(fastpathAslice(fastpathAV[:]))
  347. }
  348. // -- encode
  349. // -- -- fast path type switch
  350. func fastpathEncodeTypeSwitch(iv interface{}, e *Encoder) bool {
  351. switch v := iv.(type) {
  352. case []interface{}:
  353. fastpathTV.EncSliceIntfV(v, e)
  354. case *[]interface{}:
  355. fastpathTV.EncSliceIntfV(*v, e)
  356. case map[interface{}]interface{}:
  357. fastpathTV.EncMapIntfIntfV(v, e)
  358. case *map[interface{}]interface{}:
  359. fastpathTV.EncMapIntfIntfV(*v, e)
  360. case map[interface{}]string:
  361. fastpathTV.EncMapIntfStringV(v, e)
  362. case *map[interface{}]string:
  363. fastpathTV.EncMapIntfStringV(*v, e)
  364. case map[interface{}]uint:
  365. fastpathTV.EncMapIntfUintV(v, e)
  366. case *map[interface{}]uint:
  367. fastpathTV.EncMapIntfUintV(*v, e)
  368. case map[interface{}]uint8:
  369. fastpathTV.EncMapIntfUint8V(v, e)
  370. case *map[interface{}]uint8:
  371. fastpathTV.EncMapIntfUint8V(*v, e)
  372. case map[interface{}]uint16:
  373. fastpathTV.EncMapIntfUint16V(v, e)
  374. case *map[interface{}]uint16:
  375. fastpathTV.EncMapIntfUint16V(*v, e)
  376. case map[interface{}]uint32:
  377. fastpathTV.EncMapIntfUint32V(v, e)
  378. case *map[interface{}]uint32:
  379. fastpathTV.EncMapIntfUint32V(*v, e)
  380. case map[interface{}]uint64:
  381. fastpathTV.EncMapIntfUint64V(v, e)
  382. case *map[interface{}]uint64:
  383. fastpathTV.EncMapIntfUint64V(*v, e)
  384. case map[interface{}]uintptr:
  385. fastpathTV.EncMapIntfUintptrV(v, e)
  386. case *map[interface{}]uintptr:
  387. fastpathTV.EncMapIntfUintptrV(*v, e)
  388. case map[interface{}]int:
  389. fastpathTV.EncMapIntfIntV(v, e)
  390. case *map[interface{}]int:
  391. fastpathTV.EncMapIntfIntV(*v, e)
  392. case map[interface{}]int8:
  393. fastpathTV.EncMapIntfInt8V(v, e)
  394. case *map[interface{}]int8:
  395. fastpathTV.EncMapIntfInt8V(*v, e)
  396. case map[interface{}]int16:
  397. fastpathTV.EncMapIntfInt16V(v, e)
  398. case *map[interface{}]int16:
  399. fastpathTV.EncMapIntfInt16V(*v, e)
  400. case map[interface{}]int32:
  401. fastpathTV.EncMapIntfInt32V(v, e)
  402. case *map[interface{}]int32:
  403. fastpathTV.EncMapIntfInt32V(*v, e)
  404. case map[interface{}]int64:
  405. fastpathTV.EncMapIntfInt64V(v, e)
  406. case *map[interface{}]int64:
  407. fastpathTV.EncMapIntfInt64V(*v, e)
  408. case map[interface{}]float32:
  409. fastpathTV.EncMapIntfFloat32V(v, e)
  410. case *map[interface{}]float32:
  411. fastpathTV.EncMapIntfFloat32V(*v, e)
  412. case map[interface{}]float64:
  413. fastpathTV.EncMapIntfFloat64V(v, e)
  414. case *map[interface{}]float64:
  415. fastpathTV.EncMapIntfFloat64V(*v, e)
  416. case map[interface{}]bool:
  417. fastpathTV.EncMapIntfBoolV(v, e)
  418. case *map[interface{}]bool:
  419. fastpathTV.EncMapIntfBoolV(*v, e)
  420. case []string:
  421. fastpathTV.EncSliceStringV(v, e)
  422. case *[]string:
  423. fastpathTV.EncSliceStringV(*v, e)
  424. case map[string]interface{}:
  425. fastpathTV.EncMapStringIntfV(v, e)
  426. case *map[string]interface{}:
  427. fastpathTV.EncMapStringIntfV(*v, e)
  428. case map[string]string:
  429. fastpathTV.EncMapStringStringV(v, e)
  430. case *map[string]string:
  431. fastpathTV.EncMapStringStringV(*v, e)
  432. case map[string]uint:
  433. fastpathTV.EncMapStringUintV(v, e)
  434. case *map[string]uint:
  435. fastpathTV.EncMapStringUintV(*v, e)
  436. case map[string]uint8:
  437. fastpathTV.EncMapStringUint8V(v, e)
  438. case *map[string]uint8:
  439. fastpathTV.EncMapStringUint8V(*v, e)
  440. case map[string]uint16:
  441. fastpathTV.EncMapStringUint16V(v, e)
  442. case *map[string]uint16:
  443. fastpathTV.EncMapStringUint16V(*v, e)
  444. case map[string]uint32:
  445. fastpathTV.EncMapStringUint32V(v, e)
  446. case *map[string]uint32:
  447. fastpathTV.EncMapStringUint32V(*v, e)
  448. case map[string]uint64:
  449. fastpathTV.EncMapStringUint64V(v, e)
  450. case *map[string]uint64:
  451. fastpathTV.EncMapStringUint64V(*v, e)
  452. case map[string]uintptr:
  453. fastpathTV.EncMapStringUintptrV(v, e)
  454. case *map[string]uintptr:
  455. fastpathTV.EncMapStringUintptrV(*v, e)
  456. case map[string]int:
  457. fastpathTV.EncMapStringIntV(v, e)
  458. case *map[string]int:
  459. fastpathTV.EncMapStringIntV(*v, e)
  460. case map[string]int8:
  461. fastpathTV.EncMapStringInt8V(v, e)
  462. case *map[string]int8:
  463. fastpathTV.EncMapStringInt8V(*v, e)
  464. case map[string]int16:
  465. fastpathTV.EncMapStringInt16V(v, e)
  466. case *map[string]int16:
  467. fastpathTV.EncMapStringInt16V(*v, e)
  468. case map[string]int32:
  469. fastpathTV.EncMapStringInt32V(v, e)
  470. case *map[string]int32:
  471. fastpathTV.EncMapStringInt32V(*v, e)
  472. case map[string]int64:
  473. fastpathTV.EncMapStringInt64V(v, e)
  474. case *map[string]int64:
  475. fastpathTV.EncMapStringInt64V(*v, e)
  476. case map[string]float32:
  477. fastpathTV.EncMapStringFloat32V(v, e)
  478. case *map[string]float32:
  479. fastpathTV.EncMapStringFloat32V(*v, e)
  480. case map[string]float64:
  481. fastpathTV.EncMapStringFloat64V(v, e)
  482. case *map[string]float64:
  483. fastpathTV.EncMapStringFloat64V(*v, e)
  484. case map[string]bool:
  485. fastpathTV.EncMapStringBoolV(v, e)
  486. case *map[string]bool:
  487. fastpathTV.EncMapStringBoolV(*v, e)
  488. case []float32:
  489. fastpathTV.EncSliceFloat32V(v, e)
  490. case *[]float32:
  491. fastpathTV.EncSliceFloat32V(*v, e)
  492. case map[float32]interface{}:
  493. fastpathTV.EncMapFloat32IntfV(v, e)
  494. case *map[float32]interface{}:
  495. fastpathTV.EncMapFloat32IntfV(*v, e)
  496. case map[float32]string:
  497. fastpathTV.EncMapFloat32StringV(v, e)
  498. case *map[float32]string:
  499. fastpathTV.EncMapFloat32StringV(*v, e)
  500. case map[float32]uint:
  501. fastpathTV.EncMapFloat32UintV(v, e)
  502. case *map[float32]uint:
  503. fastpathTV.EncMapFloat32UintV(*v, e)
  504. case map[float32]uint8:
  505. fastpathTV.EncMapFloat32Uint8V(v, e)
  506. case *map[float32]uint8:
  507. fastpathTV.EncMapFloat32Uint8V(*v, e)
  508. case map[float32]uint16:
  509. fastpathTV.EncMapFloat32Uint16V(v, e)
  510. case *map[float32]uint16:
  511. fastpathTV.EncMapFloat32Uint16V(*v, e)
  512. case map[float32]uint32:
  513. fastpathTV.EncMapFloat32Uint32V(v, e)
  514. case *map[float32]uint32:
  515. fastpathTV.EncMapFloat32Uint32V(*v, e)
  516. case map[float32]uint64:
  517. fastpathTV.EncMapFloat32Uint64V(v, e)
  518. case *map[float32]uint64:
  519. fastpathTV.EncMapFloat32Uint64V(*v, e)
  520. case map[float32]uintptr:
  521. fastpathTV.EncMapFloat32UintptrV(v, e)
  522. case *map[float32]uintptr:
  523. fastpathTV.EncMapFloat32UintptrV(*v, e)
  524. case map[float32]int:
  525. fastpathTV.EncMapFloat32IntV(v, e)
  526. case *map[float32]int:
  527. fastpathTV.EncMapFloat32IntV(*v, e)
  528. case map[float32]int8:
  529. fastpathTV.EncMapFloat32Int8V(v, e)
  530. case *map[float32]int8:
  531. fastpathTV.EncMapFloat32Int8V(*v, e)
  532. case map[float32]int16:
  533. fastpathTV.EncMapFloat32Int16V(v, e)
  534. case *map[float32]int16:
  535. fastpathTV.EncMapFloat32Int16V(*v, e)
  536. case map[float32]int32:
  537. fastpathTV.EncMapFloat32Int32V(v, e)
  538. case *map[float32]int32:
  539. fastpathTV.EncMapFloat32Int32V(*v, e)
  540. case map[float32]int64:
  541. fastpathTV.EncMapFloat32Int64V(v, e)
  542. case *map[float32]int64:
  543. fastpathTV.EncMapFloat32Int64V(*v, e)
  544. case map[float32]float32:
  545. fastpathTV.EncMapFloat32Float32V(v, e)
  546. case *map[float32]float32:
  547. fastpathTV.EncMapFloat32Float32V(*v, e)
  548. case map[float32]float64:
  549. fastpathTV.EncMapFloat32Float64V(v, e)
  550. case *map[float32]float64:
  551. fastpathTV.EncMapFloat32Float64V(*v, e)
  552. case map[float32]bool:
  553. fastpathTV.EncMapFloat32BoolV(v, e)
  554. case *map[float32]bool:
  555. fastpathTV.EncMapFloat32BoolV(*v, e)
  556. case []float64:
  557. fastpathTV.EncSliceFloat64V(v, e)
  558. case *[]float64:
  559. fastpathTV.EncSliceFloat64V(*v, e)
  560. case map[float64]interface{}:
  561. fastpathTV.EncMapFloat64IntfV(v, e)
  562. case *map[float64]interface{}:
  563. fastpathTV.EncMapFloat64IntfV(*v, e)
  564. case map[float64]string:
  565. fastpathTV.EncMapFloat64StringV(v, e)
  566. case *map[float64]string:
  567. fastpathTV.EncMapFloat64StringV(*v, e)
  568. case map[float64]uint:
  569. fastpathTV.EncMapFloat64UintV(v, e)
  570. case *map[float64]uint:
  571. fastpathTV.EncMapFloat64UintV(*v, e)
  572. case map[float64]uint8:
  573. fastpathTV.EncMapFloat64Uint8V(v, e)
  574. case *map[float64]uint8:
  575. fastpathTV.EncMapFloat64Uint8V(*v, e)
  576. case map[float64]uint16:
  577. fastpathTV.EncMapFloat64Uint16V(v, e)
  578. case *map[float64]uint16:
  579. fastpathTV.EncMapFloat64Uint16V(*v, e)
  580. case map[float64]uint32:
  581. fastpathTV.EncMapFloat64Uint32V(v, e)
  582. case *map[float64]uint32:
  583. fastpathTV.EncMapFloat64Uint32V(*v, e)
  584. case map[float64]uint64:
  585. fastpathTV.EncMapFloat64Uint64V(v, e)
  586. case *map[float64]uint64:
  587. fastpathTV.EncMapFloat64Uint64V(*v, e)
  588. case map[float64]uintptr:
  589. fastpathTV.EncMapFloat64UintptrV(v, e)
  590. case *map[float64]uintptr:
  591. fastpathTV.EncMapFloat64UintptrV(*v, e)
  592. case map[float64]int:
  593. fastpathTV.EncMapFloat64IntV(v, e)
  594. case *map[float64]int:
  595. fastpathTV.EncMapFloat64IntV(*v, e)
  596. case map[float64]int8:
  597. fastpathTV.EncMapFloat64Int8V(v, e)
  598. case *map[float64]int8:
  599. fastpathTV.EncMapFloat64Int8V(*v, e)
  600. case map[float64]int16:
  601. fastpathTV.EncMapFloat64Int16V(v, e)
  602. case *map[float64]int16:
  603. fastpathTV.EncMapFloat64Int16V(*v, e)
  604. case map[float64]int32:
  605. fastpathTV.EncMapFloat64Int32V(v, e)
  606. case *map[float64]int32:
  607. fastpathTV.EncMapFloat64Int32V(*v, e)
  608. case map[float64]int64:
  609. fastpathTV.EncMapFloat64Int64V(v, e)
  610. case *map[float64]int64:
  611. fastpathTV.EncMapFloat64Int64V(*v, e)
  612. case map[float64]float32:
  613. fastpathTV.EncMapFloat64Float32V(v, e)
  614. case *map[float64]float32:
  615. fastpathTV.EncMapFloat64Float32V(*v, e)
  616. case map[float64]float64:
  617. fastpathTV.EncMapFloat64Float64V(v, e)
  618. case *map[float64]float64:
  619. fastpathTV.EncMapFloat64Float64V(*v, e)
  620. case map[float64]bool:
  621. fastpathTV.EncMapFloat64BoolV(v, e)
  622. case *map[float64]bool:
  623. fastpathTV.EncMapFloat64BoolV(*v, e)
  624. case []uint:
  625. fastpathTV.EncSliceUintV(v, e)
  626. case *[]uint:
  627. fastpathTV.EncSliceUintV(*v, e)
  628. case map[uint]interface{}:
  629. fastpathTV.EncMapUintIntfV(v, e)
  630. case *map[uint]interface{}:
  631. fastpathTV.EncMapUintIntfV(*v, e)
  632. case map[uint]string:
  633. fastpathTV.EncMapUintStringV(v, e)
  634. case *map[uint]string:
  635. fastpathTV.EncMapUintStringV(*v, e)
  636. case map[uint]uint:
  637. fastpathTV.EncMapUintUintV(v, e)
  638. case *map[uint]uint:
  639. fastpathTV.EncMapUintUintV(*v, e)
  640. case map[uint]uint8:
  641. fastpathTV.EncMapUintUint8V(v, e)
  642. case *map[uint]uint8:
  643. fastpathTV.EncMapUintUint8V(*v, e)
  644. case map[uint]uint16:
  645. fastpathTV.EncMapUintUint16V(v, e)
  646. case *map[uint]uint16:
  647. fastpathTV.EncMapUintUint16V(*v, e)
  648. case map[uint]uint32:
  649. fastpathTV.EncMapUintUint32V(v, e)
  650. case *map[uint]uint32:
  651. fastpathTV.EncMapUintUint32V(*v, e)
  652. case map[uint]uint64:
  653. fastpathTV.EncMapUintUint64V(v, e)
  654. case *map[uint]uint64:
  655. fastpathTV.EncMapUintUint64V(*v, e)
  656. case map[uint]uintptr:
  657. fastpathTV.EncMapUintUintptrV(v, e)
  658. case *map[uint]uintptr:
  659. fastpathTV.EncMapUintUintptrV(*v, e)
  660. case map[uint]int:
  661. fastpathTV.EncMapUintIntV(v, e)
  662. case *map[uint]int:
  663. fastpathTV.EncMapUintIntV(*v, e)
  664. case map[uint]int8:
  665. fastpathTV.EncMapUintInt8V(v, e)
  666. case *map[uint]int8:
  667. fastpathTV.EncMapUintInt8V(*v, e)
  668. case map[uint]int16:
  669. fastpathTV.EncMapUintInt16V(v, e)
  670. case *map[uint]int16:
  671. fastpathTV.EncMapUintInt16V(*v, e)
  672. case map[uint]int32:
  673. fastpathTV.EncMapUintInt32V(v, e)
  674. case *map[uint]int32:
  675. fastpathTV.EncMapUintInt32V(*v, e)
  676. case map[uint]int64:
  677. fastpathTV.EncMapUintInt64V(v, e)
  678. case *map[uint]int64:
  679. fastpathTV.EncMapUintInt64V(*v, e)
  680. case map[uint]float32:
  681. fastpathTV.EncMapUintFloat32V(v, e)
  682. case *map[uint]float32:
  683. fastpathTV.EncMapUintFloat32V(*v, e)
  684. case map[uint]float64:
  685. fastpathTV.EncMapUintFloat64V(v, e)
  686. case *map[uint]float64:
  687. fastpathTV.EncMapUintFloat64V(*v, e)
  688. case map[uint]bool:
  689. fastpathTV.EncMapUintBoolV(v, e)
  690. case *map[uint]bool:
  691. fastpathTV.EncMapUintBoolV(*v, e)
  692. case map[uint8]interface{}:
  693. fastpathTV.EncMapUint8IntfV(v, e)
  694. case *map[uint8]interface{}:
  695. fastpathTV.EncMapUint8IntfV(*v, e)
  696. case map[uint8]string:
  697. fastpathTV.EncMapUint8StringV(v, e)
  698. case *map[uint8]string:
  699. fastpathTV.EncMapUint8StringV(*v, e)
  700. case map[uint8]uint:
  701. fastpathTV.EncMapUint8UintV(v, e)
  702. case *map[uint8]uint:
  703. fastpathTV.EncMapUint8UintV(*v, e)
  704. case map[uint8]uint8:
  705. fastpathTV.EncMapUint8Uint8V(v, e)
  706. case *map[uint8]uint8:
  707. fastpathTV.EncMapUint8Uint8V(*v, e)
  708. case map[uint8]uint16:
  709. fastpathTV.EncMapUint8Uint16V(v, e)
  710. case *map[uint8]uint16:
  711. fastpathTV.EncMapUint8Uint16V(*v, e)
  712. case map[uint8]uint32:
  713. fastpathTV.EncMapUint8Uint32V(v, e)
  714. case *map[uint8]uint32:
  715. fastpathTV.EncMapUint8Uint32V(*v, e)
  716. case map[uint8]uint64:
  717. fastpathTV.EncMapUint8Uint64V(v, e)
  718. case *map[uint8]uint64:
  719. fastpathTV.EncMapUint8Uint64V(*v, e)
  720. case map[uint8]uintptr:
  721. fastpathTV.EncMapUint8UintptrV(v, e)
  722. case *map[uint8]uintptr:
  723. fastpathTV.EncMapUint8UintptrV(*v, e)
  724. case map[uint8]int:
  725. fastpathTV.EncMapUint8IntV(v, e)
  726. case *map[uint8]int:
  727. fastpathTV.EncMapUint8IntV(*v, e)
  728. case map[uint8]int8:
  729. fastpathTV.EncMapUint8Int8V(v, e)
  730. case *map[uint8]int8:
  731. fastpathTV.EncMapUint8Int8V(*v, e)
  732. case map[uint8]int16:
  733. fastpathTV.EncMapUint8Int16V(v, e)
  734. case *map[uint8]int16:
  735. fastpathTV.EncMapUint8Int16V(*v, e)
  736. case map[uint8]int32:
  737. fastpathTV.EncMapUint8Int32V(v, e)
  738. case *map[uint8]int32:
  739. fastpathTV.EncMapUint8Int32V(*v, e)
  740. case map[uint8]int64:
  741. fastpathTV.EncMapUint8Int64V(v, e)
  742. case *map[uint8]int64:
  743. fastpathTV.EncMapUint8Int64V(*v, e)
  744. case map[uint8]float32:
  745. fastpathTV.EncMapUint8Float32V(v, e)
  746. case *map[uint8]float32:
  747. fastpathTV.EncMapUint8Float32V(*v, e)
  748. case map[uint8]float64:
  749. fastpathTV.EncMapUint8Float64V(v, e)
  750. case *map[uint8]float64:
  751. fastpathTV.EncMapUint8Float64V(*v, e)
  752. case map[uint8]bool:
  753. fastpathTV.EncMapUint8BoolV(v, e)
  754. case *map[uint8]bool:
  755. fastpathTV.EncMapUint8BoolV(*v, e)
  756. case []uint16:
  757. fastpathTV.EncSliceUint16V(v, e)
  758. case *[]uint16:
  759. fastpathTV.EncSliceUint16V(*v, e)
  760. case map[uint16]interface{}:
  761. fastpathTV.EncMapUint16IntfV(v, e)
  762. case *map[uint16]interface{}:
  763. fastpathTV.EncMapUint16IntfV(*v, e)
  764. case map[uint16]string:
  765. fastpathTV.EncMapUint16StringV(v, e)
  766. case *map[uint16]string:
  767. fastpathTV.EncMapUint16StringV(*v, e)
  768. case map[uint16]uint:
  769. fastpathTV.EncMapUint16UintV(v, e)
  770. case *map[uint16]uint:
  771. fastpathTV.EncMapUint16UintV(*v, e)
  772. case map[uint16]uint8:
  773. fastpathTV.EncMapUint16Uint8V(v, e)
  774. case *map[uint16]uint8:
  775. fastpathTV.EncMapUint16Uint8V(*v, e)
  776. case map[uint16]uint16:
  777. fastpathTV.EncMapUint16Uint16V(v, e)
  778. case *map[uint16]uint16:
  779. fastpathTV.EncMapUint16Uint16V(*v, e)
  780. case map[uint16]uint32:
  781. fastpathTV.EncMapUint16Uint32V(v, e)
  782. case *map[uint16]uint32:
  783. fastpathTV.EncMapUint16Uint32V(*v, e)
  784. case map[uint16]uint64:
  785. fastpathTV.EncMapUint16Uint64V(v, e)
  786. case *map[uint16]uint64:
  787. fastpathTV.EncMapUint16Uint64V(*v, e)
  788. case map[uint16]uintptr:
  789. fastpathTV.EncMapUint16UintptrV(v, e)
  790. case *map[uint16]uintptr:
  791. fastpathTV.EncMapUint16UintptrV(*v, e)
  792. case map[uint16]int:
  793. fastpathTV.EncMapUint16IntV(v, e)
  794. case *map[uint16]int:
  795. fastpathTV.EncMapUint16IntV(*v, e)
  796. case map[uint16]int8:
  797. fastpathTV.EncMapUint16Int8V(v, e)
  798. case *map[uint16]int8:
  799. fastpathTV.EncMapUint16Int8V(*v, e)
  800. case map[uint16]int16:
  801. fastpathTV.EncMapUint16Int16V(v, e)
  802. case *map[uint16]int16:
  803. fastpathTV.EncMapUint16Int16V(*v, e)
  804. case map[uint16]int32:
  805. fastpathTV.EncMapUint16Int32V(v, e)
  806. case *map[uint16]int32:
  807. fastpathTV.EncMapUint16Int32V(*v, e)
  808. case map[uint16]int64:
  809. fastpathTV.EncMapUint16Int64V(v, e)
  810. case *map[uint16]int64:
  811. fastpathTV.EncMapUint16Int64V(*v, e)
  812. case map[uint16]float32:
  813. fastpathTV.EncMapUint16Float32V(v, e)
  814. case *map[uint16]float32:
  815. fastpathTV.EncMapUint16Float32V(*v, e)
  816. case map[uint16]float64:
  817. fastpathTV.EncMapUint16Float64V(v, e)
  818. case *map[uint16]float64:
  819. fastpathTV.EncMapUint16Float64V(*v, e)
  820. case map[uint16]bool:
  821. fastpathTV.EncMapUint16BoolV(v, e)
  822. case *map[uint16]bool:
  823. fastpathTV.EncMapUint16BoolV(*v, e)
  824. case []uint32:
  825. fastpathTV.EncSliceUint32V(v, e)
  826. case *[]uint32:
  827. fastpathTV.EncSliceUint32V(*v, e)
  828. case map[uint32]interface{}:
  829. fastpathTV.EncMapUint32IntfV(v, e)
  830. case *map[uint32]interface{}:
  831. fastpathTV.EncMapUint32IntfV(*v, e)
  832. case map[uint32]string:
  833. fastpathTV.EncMapUint32StringV(v, e)
  834. case *map[uint32]string:
  835. fastpathTV.EncMapUint32StringV(*v, e)
  836. case map[uint32]uint:
  837. fastpathTV.EncMapUint32UintV(v, e)
  838. case *map[uint32]uint:
  839. fastpathTV.EncMapUint32UintV(*v, e)
  840. case map[uint32]uint8:
  841. fastpathTV.EncMapUint32Uint8V(v, e)
  842. case *map[uint32]uint8:
  843. fastpathTV.EncMapUint32Uint8V(*v, e)
  844. case map[uint32]uint16:
  845. fastpathTV.EncMapUint32Uint16V(v, e)
  846. case *map[uint32]uint16:
  847. fastpathTV.EncMapUint32Uint16V(*v, e)
  848. case map[uint32]uint32:
  849. fastpathTV.EncMapUint32Uint32V(v, e)
  850. case *map[uint32]uint32:
  851. fastpathTV.EncMapUint32Uint32V(*v, e)
  852. case map[uint32]uint64:
  853. fastpathTV.EncMapUint32Uint64V(v, e)
  854. case *map[uint32]uint64:
  855. fastpathTV.EncMapUint32Uint64V(*v, e)
  856. case map[uint32]uintptr:
  857. fastpathTV.EncMapUint32UintptrV(v, e)
  858. case *map[uint32]uintptr:
  859. fastpathTV.EncMapUint32UintptrV(*v, e)
  860. case map[uint32]int:
  861. fastpathTV.EncMapUint32IntV(v, e)
  862. case *map[uint32]int:
  863. fastpathTV.EncMapUint32IntV(*v, e)
  864. case map[uint32]int8:
  865. fastpathTV.EncMapUint32Int8V(v, e)
  866. case *map[uint32]int8:
  867. fastpathTV.EncMapUint32Int8V(*v, e)
  868. case map[uint32]int16:
  869. fastpathTV.EncMapUint32Int16V(v, e)
  870. case *map[uint32]int16:
  871. fastpathTV.EncMapUint32Int16V(*v, e)
  872. case map[uint32]int32:
  873. fastpathTV.EncMapUint32Int32V(v, e)
  874. case *map[uint32]int32:
  875. fastpathTV.EncMapUint32Int32V(*v, e)
  876. case map[uint32]int64:
  877. fastpathTV.EncMapUint32Int64V(v, e)
  878. case *map[uint32]int64:
  879. fastpathTV.EncMapUint32Int64V(*v, e)
  880. case map[uint32]float32:
  881. fastpathTV.EncMapUint32Float32V(v, e)
  882. case *map[uint32]float32:
  883. fastpathTV.EncMapUint32Float32V(*v, e)
  884. case map[uint32]float64:
  885. fastpathTV.EncMapUint32Float64V(v, e)
  886. case *map[uint32]float64:
  887. fastpathTV.EncMapUint32Float64V(*v, e)
  888. case map[uint32]bool:
  889. fastpathTV.EncMapUint32BoolV(v, e)
  890. case *map[uint32]bool:
  891. fastpathTV.EncMapUint32BoolV(*v, e)
  892. case []uint64:
  893. fastpathTV.EncSliceUint64V(v, e)
  894. case *[]uint64:
  895. fastpathTV.EncSliceUint64V(*v, e)
  896. case map[uint64]interface{}:
  897. fastpathTV.EncMapUint64IntfV(v, e)
  898. case *map[uint64]interface{}:
  899. fastpathTV.EncMapUint64IntfV(*v, e)
  900. case map[uint64]string:
  901. fastpathTV.EncMapUint64StringV(v, e)
  902. case *map[uint64]string:
  903. fastpathTV.EncMapUint64StringV(*v, e)
  904. case map[uint64]uint:
  905. fastpathTV.EncMapUint64UintV(v, e)
  906. case *map[uint64]uint:
  907. fastpathTV.EncMapUint64UintV(*v, e)
  908. case map[uint64]uint8:
  909. fastpathTV.EncMapUint64Uint8V(v, e)
  910. case *map[uint64]uint8:
  911. fastpathTV.EncMapUint64Uint8V(*v, e)
  912. case map[uint64]uint16:
  913. fastpathTV.EncMapUint64Uint16V(v, e)
  914. case *map[uint64]uint16:
  915. fastpathTV.EncMapUint64Uint16V(*v, e)
  916. case map[uint64]uint32:
  917. fastpathTV.EncMapUint64Uint32V(v, e)
  918. case *map[uint64]uint32:
  919. fastpathTV.EncMapUint64Uint32V(*v, e)
  920. case map[uint64]uint64:
  921. fastpathTV.EncMapUint64Uint64V(v, e)
  922. case *map[uint64]uint64:
  923. fastpathTV.EncMapUint64Uint64V(*v, e)
  924. case map[uint64]uintptr:
  925. fastpathTV.EncMapUint64UintptrV(v, e)
  926. case *map[uint64]uintptr:
  927. fastpathTV.EncMapUint64UintptrV(*v, e)
  928. case map[uint64]int:
  929. fastpathTV.EncMapUint64IntV(v, e)
  930. case *map[uint64]int:
  931. fastpathTV.EncMapUint64IntV(*v, e)
  932. case map[uint64]int8:
  933. fastpathTV.EncMapUint64Int8V(v, e)
  934. case *map[uint64]int8:
  935. fastpathTV.EncMapUint64Int8V(*v, e)
  936. case map[uint64]int16:
  937. fastpathTV.EncMapUint64Int16V(v, e)
  938. case *map[uint64]int16:
  939. fastpathTV.EncMapUint64Int16V(*v, e)
  940. case map[uint64]int32:
  941. fastpathTV.EncMapUint64Int32V(v, e)
  942. case *map[uint64]int32:
  943. fastpathTV.EncMapUint64Int32V(*v, e)
  944. case map[uint64]int64:
  945. fastpathTV.EncMapUint64Int64V(v, e)
  946. case *map[uint64]int64:
  947. fastpathTV.EncMapUint64Int64V(*v, e)
  948. case map[uint64]float32:
  949. fastpathTV.EncMapUint64Float32V(v, e)
  950. case *map[uint64]float32:
  951. fastpathTV.EncMapUint64Float32V(*v, e)
  952. case map[uint64]float64:
  953. fastpathTV.EncMapUint64Float64V(v, e)
  954. case *map[uint64]float64:
  955. fastpathTV.EncMapUint64Float64V(*v, e)
  956. case map[uint64]bool:
  957. fastpathTV.EncMapUint64BoolV(v, e)
  958. case *map[uint64]bool:
  959. fastpathTV.EncMapUint64BoolV(*v, e)
  960. case []uintptr:
  961. fastpathTV.EncSliceUintptrV(v, e)
  962. case *[]uintptr:
  963. fastpathTV.EncSliceUintptrV(*v, e)
  964. case map[uintptr]interface{}:
  965. fastpathTV.EncMapUintptrIntfV(v, e)
  966. case *map[uintptr]interface{}:
  967. fastpathTV.EncMapUintptrIntfV(*v, e)
  968. case map[uintptr]string:
  969. fastpathTV.EncMapUintptrStringV(v, e)
  970. case *map[uintptr]string:
  971. fastpathTV.EncMapUintptrStringV(*v, e)
  972. case map[uintptr]uint:
  973. fastpathTV.EncMapUintptrUintV(v, e)
  974. case *map[uintptr]uint:
  975. fastpathTV.EncMapUintptrUintV(*v, e)
  976. case map[uintptr]uint8:
  977. fastpathTV.EncMapUintptrUint8V(v, e)
  978. case *map[uintptr]uint8:
  979. fastpathTV.EncMapUintptrUint8V(*v, e)
  980. case map[uintptr]uint16:
  981. fastpathTV.EncMapUintptrUint16V(v, e)
  982. case *map[uintptr]uint16:
  983. fastpathTV.EncMapUintptrUint16V(*v, e)
  984. case map[uintptr]uint32:
  985. fastpathTV.EncMapUintptrUint32V(v, e)
  986. case *map[uintptr]uint32:
  987. fastpathTV.EncMapUintptrUint32V(*v, e)
  988. case map[uintptr]uint64:
  989. fastpathTV.EncMapUintptrUint64V(v, e)
  990. case *map[uintptr]uint64:
  991. fastpathTV.EncMapUintptrUint64V(*v, e)
  992. case map[uintptr]uintptr:
  993. fastpathTV.EncMapUintptrUintptrV(v, e)
  994. case *map[uintptr]uintptr:
  995. fastpathTV.EncMapUintptrUintptrV(*v, e)
  996. case map[uintptr]int:
  997. fastpathTV.EncMapUintptrIntV(v, e)
  998. case *map[uintptr]int:
  999. fastpathTV.EncMapUintptrIntV(*v, e)
  1000. case map[uintptr]int8:
  1001. fastpathTV.EncMapUintptrInt8V(v, e)
  1002. case *map[uintptr]int8:
  1003. fastpathTV.EncMapUintptrInt8V(*v, e)
  1004. case map[uintptr]int16:
  1005. fastpathTV.EncMapUintptrInt16V(v, e)
  1006. case *map[uintptr]int16:
  1007. fastpathTV.EncMapUintptrInt16V(*v, e)
  1008. case map[uintptr]int32:
  1009. fastpathTV.EncMapUintptrInt32V(v, e)
  1010. case *map[uintptr]int32:
  1011. fastpathTV.EncMapUintptrInt32V(*v, e)
  1012. case map[uintptr]int64:
  1013. fastpathTV.EncMapUintptrInt64V(v, e)
  1014. case *map[uintptr]int64:
  1015. fastpathTV.EncMapUintptrInt64V(*v, e)
  1016. case map[uintptr]float32:
  1017. fastpathTV.EncMapUintptrFloat32V(v, e)
  1018. case *map[uintptr]float32:
  1019. fastpathTV.EncMapUintptrFloat32V(*v, e)
  1020. case map[uintptr]float64:
  1021. fastpathTV.EncMapUintptrFloat64V(v, e)
  1022. case *map[uintptr]float64:
  1023. fastpathTV.EncMapUintptrFloat64V(*v, e)
  1024. case map[uintptr]bool:
  1025. fastpathTV.EncMapUintptrBoolV(v, e)
  1026. case *map[uintptr]bool:
  1027. fastpathTV.EncMapUintptrBoolV(*v, e)
  1028. case []int:
  1029. fastpathTV.EncSliceIntV(v, e)
  1030. case *[]int:
  1031. fastpathTV.EncSliceIntV(*v, e)
  1032. case map[int]interface{}:
  1033. fastpathTV.EncMapIntIntfV(v, e)
  1034. case *map[int]interface{}:
  1035. fastpathTV.EncMapIntIntfV(*v, e)
  1036. case map[int]string:
  1037. fastpathTV.EncMapIntStringV(v, e)
  1038. case *map[int]string:
  1039. fastpathTV.EncMapIntStringV(*v, e)
  1040. case map[int]uint:
  1041. fastpathTV.EncMapIntUintV(v, e)
  1042. case *map[int]uint:
  1043. fastpathTV.EncMapIntUintV(*v, e)
  1044. case map[int]uint8:
  1045. fastpathTV.EncMapIntUint8V(v, e)
  1046. case *map[int]uint8:
  1047. fastpathTV.EncMapIntUint8V(*v, e)
  1048. case map[int]uint16:
  1049. fastpathTV.EncMapIntUint16V(v, e)
  1050. case *map[int]uint16:
  1051. fastpathTV.EncMapIntUint16V(*v, e)
  1052. case map[int]uint32:
  1053. fastpathTV.EncMapIntUint32V(v, e)
  1054. case *map[int]uint32:
  1055. fastpathTV.EncMapIntUint32V(*v, e)
  1056. case map[int]uint64:
  1057. fastpathTV.EncMapIntUint64V(v, e)
  1058. case *map[int]uint64:
  1059. fastpathTV.EncMapIntUint64V(*v, e)
  1060. case map[int]uintptr:
  1061. fastpathTV.EncMapIntUintptrV(v, e)
  1062. case *map[int]uintptr:
  1063. fastpathTV.EncMapIntUintptrV(*v, e)
  1064. case map[int]int:
  1065. fastpathTV.EncMapIntIntV(v, e)
  1066. case *map[int]int:
  1067. fastpathTV.EncMapIntIntV(*v, e)
  1068. case map[int]int8:
  1069. fastpathTV.EncMapIntInt8V(v, e)
  1070. case *map[int]int8:
  1071. fastpathTV.EncMapIntInt8V(*v, e)
  1072. case map[int]int16:
  1073. fastpathTV.EncMapIntInt16V(v, e)
  1074. case *map[int]int16:
  1075. fastpathTV.EncMapIntInt16V(*v, e)
  1076. case map[int]int32:
  1077. fastpathTV.EncMapIntInt32V(v, e)
  1078. case *map[int]int32:
  1079. fastpathTV.EncMapIntInt32V(*v, e)
  1080. case map[int]int64:
  1081. fastpathTV.EncMapIntInt64V(v, e)
  1082. case *map[int]int64:
  1083. fastpathTV.EncMapIntInt64V(*v, e)
  1084. case map[int]float32:
  1085. fastpathTV.EncMapIntFloat32V(v, e)
  1086. case *map[int]float32:
  1087. fastpathTV.EncMapIntFloat32V(*v, e)
  1088. case map[int]float64:
  1089. fastpathTV.EncMapIntFloat64V(v, e)
  1090. case *map[int]float64:
  1091. fastpathTV.EncMapIntFloat64V(*v, e)
  1092. case map[int]bool:
  1093. fastpathTV.EncMapIntBoolV(v, e)
  1094. case *map[int]bool:
  1095. fastpathTV.EncMapIntBoolV(*v, e)
  1096. case []int8:
  1097. fastpathTV.EncSliceInt8V(v, e)
  1098. case *[]int8:
  1099. fastpathTV.EncSliceInt8V(*v, e)
  1100. case map[int8]interface{}:
  1101. fastpathTV.EncMapInt8IntfV(v, e)
  1102. case *map[int8]interface{}:
  1103. fastpathTV.EncMapInt8IntfV(*v, e)
  1104. case map[int8]string:
  1105. fastpathTV.EncMapInt8StringV(v, e)
  1106. case *map[int8]string:
  1107. fastpathTV.EncMapInt8StringV(*v, e)
  1108. case map[int8]uint:
  1109. fastpathTV.EncMapInt8UintV(v, e)
  1110. case *map[int8]uint:
  1111. fastpathTV.EncMapInt8UintV(*v, e)
  1112. case map[int8]uint8:
  1113. fastpathTV.EncMapInt8Uint8V(v, e)
  1114. case *map[int8]uint8:
  1115. fastpathTV.EncMapInt8Uint8V(*v, e)
  1116. case map[int8]uint16:
  1117. fastpathTV.EncMapInt8Uint16V(v, e)
  1118. case *map[int8]uint16:
  1119. fastpathTV.EncMapInt8Uint16V(*v, e)
  1120. case map[int8]uint32:
  1121. fastpathTV.EncMapInt8Uint32V(v, e)
  1122. case *map[int8]uint32:
  1123. fastpathTV.EncMapInt8Uint32V(*v, e)
  1124. case map[int8]uint64:
  1125. fastpathTV.EncMapInt8Uint64V(v, e)
  1126. case *map[int8]uint64:
  1127. fastpathTV.EncMapInt8Uint64V(*v, e)
  1128. case map[int8]uintptr:
  1129. fastpathTV.EncMapInt8UintptrV(v, e)
  1130. case *map[int8]uintptr:
  1131. fastpathTV.EncMapInt8UintptrV(*v, e)
  1132. case map[int8]int:
  1133. fastpathTV.EncMapInt8IntV(v, e)
  1134. case *map[int8]int:
  1135. fastpathTV.EncMapInt8IntV(*v, e)
  1136. case map[int8]int8:
  1137. fastpathTV.EncMapInt8Int8V(v, e)
  1138. case *map[int8]int8:
  1139. fastpathTV.EncMapInt8Int8V(*v, e)
  1140. case map[int8]int16:
  1141. fastpathTV.EncMapInt8Int16V(v, e)
  1142. case *map[int8]int16:
  1143. fastpathTV.EncMapInt8Int16V(*v, e)
  1144. case map[int8]int32:
  1145. fastpathTV.EncMapInt8Int32V(v, e)
  1146. case *map[int8]int32:
  1147. fastpathTV.EncMapInt8Int32V(*v, e)
  1148. case map[int8]int64:
  1149. fastpathTV.EncMapInt8Int64V(v, e)
  1150. case *map[int8]int64:
  1151. fastpathTV.EncMapInt8Int64V(*v, e)
  1152. case map[int8]float32:
  1153. fastpathTV.EncMapInt8Float32V(v, e)
  1154. case *map[int8]float32:
  1155. fastpathTV.EncMapInt8Float32V(*v, e)
  1156. case map[int8]float64:
  1157. fastpathTV.EncMapInt8Float64V(v, e)
  1158. case *map[int8]float64:
  1159. fastpathTV.EncMapInt8Float64V(*v, e)
  1160. case map[int8]bool:
  1161. fastpathTV.EncMapInt8BoolV(v, e)
  1162. case *map[int8]bool:
  1163. fastpathTV.EncMapInt8BoolV(*v, e)
  1164. case []int16:
  1165. fastpathTV.EncSliceInt16V(v, e)
  1166. case *[]int16:
  1167. fastpathTV.EncSliceInt16V(*v, e)
  1168. case map[int16]interface{}:
  1169. fastpathTV.EncMapInt16IntfV(v, e)
  1170. case *map[int16]interface{}:
  1171. fastpathTV.EncMapInt16IntfV(*v, e)
  1172. case map[int16]string:
  1173. fastpathTV.EncMapInt16StringV(v, e)
  1174. case *map[int16]string:
  1175. fastpathTV.EncMapInt16StringV(*v, e)
  1176. case map[int16]uint:
  1177. fastpathTV.EncMapInt16UintV(v, e)
  1178. case *map[int16]uint:
  1179. fastpathTV.EncMapInt16UintV(*v, e)
  1180. case map[int16]uint8:
  1181. fastpathTV.EncMapInt16Uint8V(v, e)
  1182. case *map[int16]uint8:
  1183. fastpathTV.EncMapInt16Uint8V(*v, e)
  1184. case map[int16]uint16:
  1185. fastpathTV.EncMapInt16Uint16V(v, e)
  1186. case *map[int16]uint16:
  1187. fastpathTV.EncMapInt16Uint16V(*v, e)
  1188. case map[int16]uint32:
  1189. fastpathTV.EncMapInt16Uint32V(v, e)
  1190. case *map[int16]uint32:
  1191. fastpathTV.EncMapInt16Uint32V(*v, e)
  1192. case map[int16]uint64:
  1193. fastpathTV.EncMapInt16Uint64V(v, e)
  1194. case *map[int16]uint64:
  1195. fastpathTV.EncMapInt16Uint64V(*v, e)
  1196. case map[int16]uintptr:
  1197. fastpathTV.EncMapInt16UintptrV(v, e)
  1198. case *map[int16]uintptr:
  1199. fastpathTV.EncMapInt16UintptrV(*v, e)
  1200. case map[int16]int:
  1201. fastpathTV.EncMapInt16IntV(v, e)
  1202. case *map[int16]int:
  1203. fastpathTV.EncMapInt16IntV(*v, e)
  1204. case map[int16]int8:
  1205. fastpathTV.EncMapInt16Int8V(v, e)
  1206. case *map[int16]int8:
  1207. fastpathTV.EncMapInt16Int8V(*v, e)
  1208. case map[int16]int16:
  1209. fastpathTV.EncMapInt16Int16V(v, e)
  1210. case *map[int16]int16:
  1211. fastpathTV.EncMapInt16Int16V(*v, e)
  1212. case map[int16]int32:
  1213. fastpathTV.EncMapInt16Int32V(v, e)
  1214. case *map[int16]int32:
  1215. fastpathTV.EncMapInt16Int32V(*v, e)
  1216. case map[int16]int64:
  1217. fastpathTV.EncMapInt16Int64V(v, e)
  1218. case *map[int16]int64:
  1219. fastpathTV.EncMapInt16Int64V(*v, e)
  1220. case map[int16]float32:
  1221. fastpathTV.EncMapInt16Float32V(v, e)
  1222. case *map[int16]float32:
  1223. fastpathTV.EncMapInt16Float32V(*v, e)
  1224. case map[int16]float64:
  1225. fastpathTV.EncMapInt16Float64V(v, e)
  1226. case *map[int16]float64:
  1227. fastpathTV.EncMapInt16Float64V(*v, e)
  1228. case map[int16]bool:
  1229. fastpathTV.EncMapInt16BoolV(v, e)
  1230. case *map[int16]bool:
  1231. fastpathTV.EncMapInt16BoolV(*v, e)
  1232. case []int32:
  1233. fastpathTV.EncSliceInt32V(v, e)
  1234. case *[]int32:
  1235. fastpathTV.EncSliceInt32V(*v, e)
  1236. case map[int32]interface{}:
  1237. fastpathTV.EncMapInt32IntfV(v, e)
  1238. case *map[int32]interface{}:
  1239. fastpathTV.EncMapInt32IntfV(*v, e)
  1240. case map[int32]string:
  1241. fastpathTV.EncMapInt32StringV(v, e)
  1242. case *map[int32]string:
  1243. fastpathTV.EncMapInt32StringV(*v, e)
  1244. case map[int32]uint:
  1245. fastpathTV.EncMapInt32UintV(v, e)
  1246. case *map[int32]uint:
  1247. fastpathTV.EncMapInt32UintV(*v, e)
  1248. case map[int32]uint8:
  1249. fastpathTV.EncMapInt32Uint8V(v, e)
  1250. case *map[int32]uint8:
  1251. fastpathTV.EncMapInt32Uint8V(*v, e)
  1252. case map[int32]uint16:
  1253. fastpathTV.EncMapInt32Uint16V(v, e)
  1254. case *map[int32]uint16:
  1255. fastpathTV.EncMapInt32Uint16V(*v, e)
  1256. case map[int32]uint32:
  1257. fastpathTV.EncMapInt32Uint32V(v, e)
  1258. case *map[int32]uint32:
  1259. fastpathTV.EncMapInt32Uint32V(*v, e)
  1260. case map[int32]uint64:
  1261. fastpathTV.EncMapInt32Uint64V(v, e)
  1262. case *map[int32]uint64:
  1263. fastpathTV.EncMapInt32Uint64V(*v, e)
  1264. case map[int32]uintptr:
  1265. fastpathTV.EncMapInt32UintptrV(v, e)
  1266. case *map[int32]uintptr:
  1267. fastpathTV.EncMapInt32UintptrV(*v, e)
  1268. case map[int32]int:
  1269. fastpathTV.EncMapInt32IntV(v, e)
  1270. case *map[int32]int:
  1271. fastpathTV.EncMapInt32IntV(*v, e)
  1272. case map[int32]int8:
  1273. fastpathTV.EncMapInt32Int8V(v, e)
  1274. case *map[int32]int8:
  1275. fastpathTV.EncMapInt32Int8V(*v, e)
  1276. case map[int32]int16:
  1277. fastpathTV.EncMapInt32Int16V(v, e)
  1278. case *map[int32]int16:
  1279. fastpathTV.EncMapInt32Int16V(*v, e)
  1280. case map[int32]int32:
  1281. fastpathTV.EncMapInt32Int32V(v, e)
  1282. case *map[int32]int32:
  1283. fastpathTV.EncMapInt32Int32V(*v, e)
  1284. case map[int32]int64:
  1285. fastpathTV.EncMapInt32Int64V(v, e)
  1286. case *map[int32]int64:
  1287. fastpathTV.EncMapInt32Int64V(*v, e)
  1288. case map[int32]float32:
  1289. fastpathTV.EncMapInt32Float32V(v, e)
  1290. case *map[int32]float32:
  1291. fastpathTV.EncMapInt32Float32V(*v, e)
  1292. case map[int32]float64:
  1293. fastpathTV.EncMapInt32Float64V(v, e)
  1294. case *map[int32]float64:
  1295. fastpathTV.EncMapInt32Float64V(*v, e)
  1296. case map[int32]bool:
  1297. fastpathTV.EncMapInt32BoolV(v, e)
  1298. case *map[int32]bool:
  1299. fastpathTV.EncMapInt32BoolV(*v, e)
  1300. case []int64:
  1301. fastpathTV.EncSliceInt64V(v, e)
  1302. case *[]int64:
  1303. fastpathTV.EncSliceInt64V(*v, e)
  1304. case map[int64]interface{}:
  1305. fastpathTV.EncMapInt64IntfV(v, e)
  1306. case *map[int64]interface{}:
  1307. fastpathTV.EncMapInt64IntfV(*v, e)
  1308. case map[int64]string:
  1309. fastpathTV.EncMapInt64StringV(v, e)
  1310. case *map[int64]string:
  1311. fastpathTV.EncMapInt64StringV(*v, e)
  1312. case map[int64]uint:
  1313. fastpathTV.EncMapInt64UintV(v, e)
  1314. case *map[int64]uint:
  1315. fastpathTV.EncMapInt64UintV(*v, e)
  1316. case map[int64]uint8:
  1317. fastpathTV.EncMapInt64Uint8V(v, e)
  1318. case *map[int64]uint8:
  1319. fastpathTV.EncMapInt64Uint8V(*v, e)
  1320. case map[int64]uint16:
  1321. fastpathTV.EncMapInt64Uint16V(v, e)
  1322. case *map[int64]uint16:
  1323. fastpathTV.EncMapInt64Uint16V(*v, e)
  1324. case map[int64]uint32:
  1325. fastpathTV.EncMapInt64Uint32V(v, e)
  1326. case *map[int64]uint32:
  1327. fastpathTV.EncMapInt64Uint32V(*v, e)
  1328. case map[int64]uint64:
  1329. fastpathTV.EncMapInt64Uint64V(v, e)
  1330. case *map[int64]uint64:
  1331. fastpathTV.EncMapInt64Uint64V(*v, e)
  1332. case map[int64]uintptr:
  1333. fastpathTV.EncMapInt64UintptrV(v, e)
  1334. case *map[int64]uintptr:
  1335. fastpathTV.EncMapInt64UintptrV(*v, e)
  1336. case map[int64]int:
  1337. fastpathTV.EncMapInt64IntV(v, e)
  1338. case *map[int64]int:
  1339. fastpathTV.EncMapInt64IntV(*v, e)
  1340. case map[int64]int8:
  1341. fastpathTV.EncMapInt64Int8V(v, e)
  1342. case *map[int64]int8:
  1343. fastpathTV.EncMapInt64Int8V(*v, e)
  1344. case map[int64]int16:
  1345. fastpathTV.EncMapInt64Int16V(v, e)
  1346. case *map[int64]int16:
  1347. fastpathTV.EncMapInt64Int16V(*v, e)
  1348. case map[int64]int32:
  1349. fastpathTV.EncMapInt64Int32V(v, e)
  1350. case *map[int64]int32:
  1351. fastpathTV.EncMapInt64Int32V(*v, e)
  1352. case map[int64]int64:
  1353. fastpathTV.EncMapInt64Int64V(v, e)
  1354. case *map[int64]int64:
  1355. fastpathTV.EncMapInt64Int64V(*v, e)
  1356. case map[int64]float32:
  1357. fastpathTV.EncMapInt64Float32V(v, e)
  1358. case *map[int64]float32:
  1359. fastpathTV.EncMapInt64Float32V(*v, e)
  1360. case map[int64]float64:
  1361. fastpathTV.EncMapInt64Float64V(v, e)
  1362. case *map[int64]float64:
  1363. fastpathTV.EncMapInt64Float64V(*v, e)
  1364. case map[int64]bool:
  1365. fastpathTV.EncMapInt64BoolV(v, e)
  1366. case *map[int64]bool:
  1367. fastpathTV.EncMapInt64BoolV(*v, e)
  1368. case []bool:
  1369. fastpathTV.EncSliceBoolV(v, e)
  1370. case *[]bool:
  1371. fastpathTV.EncSliceBoolV(*v, e)
  1372. case map[bool]interface{}:
  1373. fastpathTV.EncMapBoolIntfV(v, e)
  1374. case *map[bool]interface{}:
  1375. fastpathTV.EncMapBoolIntfV(*v, e)
  1376. case map[bool]string:
  1377. fastpathTV.EncMapBoolStringV(v, e)
  1378. case *map[bool]string:
  1379. fastpathTV.EncMapBoolStringV(*v, e)
  1380. case map[bool]uint:
  1381. fastpathTV.EncMapBoolUintV(v, e)
  1382. case *map[bool]uint:
  1383. fastpathTV.EncMapBoolUintV(*v, e)
  1384. case map[bool]uint8:
  1385. fastpathTV.EncMapBoolUint8V(v, e)
  1386. case *map[bool]uint8:
  1387. fastpathTV.EncMapBoolUint8V(*v, e)
  1388. case map[bool]uint16:
  1389. fastpathTV.EncMapBoolUint16V(v, e)
  1390. case *map[bool]uint16:
  1391. fastpathTV.EncMapBoolUint16V(*v, e)
  1392. case map[bool]uint32:
  1393. fastpathTV.EncMapBoolUint32V(v, e)
  1394. case *map[bool]uint32:
  1395. fastpathTV.EncMapBoolUint32V(*v, e)
  1396. case map[bool]uint64:
  1397. fastpathTV.EncMapBoolUint64V(v, e)
  1398. case *map[bool]uint64:
  1399. fastpathTV.EncMapBoolUint64V(*v, e)
  1400. case map[bool]uintptr:
  1401. fastpathTV.EncMapBoolUintptrV(v, e)
  1402. case *map[bool]uintptr:
  1403. fastpathTV.EncMapBoolUintptrV(*v, e)
  1404. case map[bool]int:
  1405. fastpathTV.EncMapBoolIntV(v, e)
  1406. case *map[bool]int:
  1407. fastpathTV.EncMapBoolIntV(*v, e)
  1408. case map[bool]int8:
  1409. fastpathTV.EncMapBoolInt8V(v, e)
  1410. case *map[bool]int8:
  1411. fastpathTV.EncMapBoolInt8V(*v, e)
  1412. case map[bool]int16:
  1413. fastpathTV.EncMapBoolInt16V(v, e)
  1414. case *map[bool]int16:
  1415. fastpathTV.EncMapBoolInt16V(*v, e)
  1416. case map[bool]int32:
  1417. fastpathTV.EncMapBoolInt32V(v, e)
  1418. case *map[bool]int32:
  1419. fastpathTV.EncMapBoolInt32V(*v, e)
  1420. case map[bool]int64:
  1421. fastpathTV.EncMapBoolInt64V(v, e)
  1422. case *map[bool]int64:
  1423. fastpathTV.EncMapBoolInt64V(*v, e)
  1424. case map[bool]float32:
  1425. fastpathTV.EncMapBoolFloat32V(v, e)
  1426. case *map[bool]float32:
  1427. fastpathTV.EncMapBoolFloat32V(*v, e)
  1428. case map[bool]float64:
  1429. fastpathTV.EncMapBoolFloat64V(v, e)
  1430. case *map[bool]float64:
  1431. fastpathTV.EncMapBoolFloat64V(*v, e)
  1432. case map[bool]bool:
  1433. fastpathTV.EncMapBoolBoolV(v, e)
  1434. case *map[bool]bool:
  1435. fastpathTV.EncMapBoolBoolV(*v, e)
  1436. default:
  1437. _ = v // TODO: workaround https://github.com/golang/go/issues/12927 (remove after go 1.6 release)
  1438. return false
  1439. }
  1440. return true
  1441. }
  1442. // -- -- fast path functions
  1443. func (e *Encoder) fastpathEncSliceIntfR(f *codecFnInfo, rv reflect.Value) {
  1444. if f.ti.mbs {
  1445. fastpathTV.EncAsMapSliceIntfV(rv2i(rv).([]interface{}), e)
  1446. } else {
  1447. fastpathTV.EncSliceIntfV(rv2i(rv).([]interface{}), e)
  1448. }
  1449. }
  1450. func (_ fastpathT) EncSliceIntfV(v []interface{}, e *Encoder) {
  1451. if v == nil {
  1452. e.e.EncodeNil()
  1453. return
  1454. }
  1455. ee, esep := e.e, e.hh.hasElemSeparators()
  1456. ee.WriteArrayStart(len(v))
  1457. for _, v2 := range v {
  1458. if esep {
  1459. ee.WriteArrayElem()
  1460. }
  1461. e.encode(v2)
  1462. }
  1463. ee.WriteArrayEnd()
  1464. }
  1465. func (_ fastpathT) EncAsMapSliceIntfV(v []interface{}, e *Encoder) {
  1466. ee, esep := e.e, e.hh.hasElemSeparators()
  1467. if len(v)%2 == 1 {
  1468. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  1469. return
  1470. }
  1471. ee.WriteMapStart(len(v) / 2)
  1472. for j, v2 := range v {
  1473. if esep {
  1474. if j%2 == 0 {
  1475. ee.WriteMapElemKey()
  1476. } else {
  1477. ee.WriteMapElemValue()
  1478. }
  1479. }
  1480. e.encode(v2)
  1481. }
  1482. ee.WriteMapEnd()
  1483. }
  1484. func (e *Encoder) fastpathEncSliceStringR(f *codecFnInfo, rv reflect.Value) {
  1485. if f.ti.mbs {
  1486. fastpathTV.EncAsMapSliceStringV(rv2i(rv).([]string), e)
  1487. } else {
  1488. fastpathTV.EncSliceStringV(rv2i(rv).([]string), e)
  1489. }
  1490. }
  1491. func (_ fastpathT) EncSliceStringV(v []string, e *Encoder) {
  1492. if v == nil {
  1493. e.e.EncodeNil()
  1494. return
  1495. }
  1496. ee, esep := e.e, e.hh.hasElemSeparators()
  1497. ee.WriteArrayStart(len(v))
  1498. for _, v2 := range v {
  1499. if esep {
  1500. ee.WriteArrayElem()
  1501. }
  1502. ee.EncodeString(cUTF8, v2)
  1503. }
  1504. ee.WriteArrayEnd()
  1505. }
  1506. func (_ fastpathT) EncAsMapSliceStringV(v []string, e *Encoder) {
  1507. ee, esep := e.e, e.hh.hasElemSeparators()
  1508. if len(v)%2 == 1 {
  1509. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  1510. return
  1511. }
  1512. ee.WriteMapStart(len(v) / 2)
  1513. for j, v2 := range v {
  1514. if esep {
  1515. if j%2 == 0 {
  1516. ee.WriteMapElemKey()
  1517. } else {
  1518. ee.WriteMapElemValue()
  1519. }
  1520. }
  1521. ee.EncodeString(cUTF8, v2)
  1522. }
  1523. ee.WriteMapEnd()
  1524. }
  1525. func (e *Encoder) fastpathEncSliceFloat32R(f *codecFnInfo, rv reflect.Value) {
  1526. if f.ti.mbs {
  1527. fastpathTV.EncAsMapSliceFloat32V(rv2i(rv).([]float32), e)
  1528. } else {
  1529. fastpathTV.EncSliceFloat32V(rv2i(rv).([]float32), e)
  1530. }
  1531. }
  1532. func (_ fastpathT) EncSliceFloat32V(v []float32, e *Encoder) {
  1533. if v == nil {
  1534. e.e.EncodeNil()
  1535. return
  1536. }
  1537. ee, esep := e.e, e.hh.hasElemSeparators()
  1538. ee.WriteArrayStart(len(v))
  1539. for _, v2 := range v {
  1540. if esep {
  1541. ee.WriteArrayElem()
  1542. }
  1543. ee.EncodeFloat32(v2)
  1544. }
  1545. ee.WriteArrayEnd()
  1546. }
  1547. func (_ fastpathT) EncAsMapSliceFloat32V(v []float32, e *Encoder) {
  1548. ee, esep := e.e, e.hh.hasElemSeparators()
  1549. if len(v)%2 == 1 {
  1550. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  1551. return
  1552. }
  1553. ee.WriteMapStart(len(v) / 2)
  1554. for j, v2 := range v {
  1555. if esep {
  1556. if j%2 == 0 {
  1557. ee.WriteMapElemKey()
  1558. } else {
  1559. ee.WriteMapElemValue()
  1560. }
  1561. }
  1562. ee.EncodeFloat32(v2)
  1563. }
  1564. ee.WriteMapEnd()
  1565. }
  1566. func (e *Encoder) fastpathEncSliceFloat64R(f *codecFnInfo, rv reflect.Value) {
  1567. if f.ti.mbs {
  1568. fastpathTV.EncAsMapSliceFloat64V(rv2i(rv).([]float64), e)
  1569. } else {
  1570. fastpathTV.EncSliceFloat64V(rv2i(rv).([]float64), e)
  1571. }
  1572. }
  1573. func (_ fastpathT) EncSliceFloat64V(v []float64, e *Encoder) {
  1574. if v == nil {
  1575. e.e.EncodeNil()
  1576. return
  1577. }
  1578. ee, esep := e.e, e.hh.hasElemSeparators()
  1579. ee.WriteArrayStart(len(v))
  1580. for _, v2 := range v {
  1581. if esep {
  1582. ee.WriteArrayElem()
  1583. }
  1584. ee.EncodeFloat64(v2)
  1585. }
  1586. ee.WriteArrayEnd()
  1587. }
  1588. func (_ fastpathT) EncAsMapSliceFloat64V(v []float64, e *Encoder) {
  1589. ee, esep := e.e, e.hh.hasElemSeparators()
  1590. if len(v)%2 == 1 {
  1591. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  1592. return
  1593. }
  1594. ee.WriteMapStart(len(v) / 2)
  1595. for j, v2 := range v {
  1596. if esep {
  1597. if j%2 == 0 {
  1598. ee.WriteMapElemKey()
  1599. } else {
  1600. ee.WriteMapElemValue()
  1601. }
  1602. }
  1603. ee.EncodeFloat64(v2)
  1604. }
  1605. ee.WriteMapEnd()
  1606. }
  1607. func (e *Encoder) fastpathEncSliceUintR(f *codecFnInfo, rv reflect.Value) {
  1608. if f.ti.mbs {
  1609. fastpathTV.EncAsMapSliceUintV(rv2i(rv).([]uint), e)
  1610. } else {
  1611. fastpathTV.EncSliceUintV(rv2i(rv).([]uint), e)
  1612. }
  1613. }
  1614. func (_ fastpathT) EncSliceUintV(v []uint, e *Encoder) {
  1615. if v == nil {
  1616. e.e.EncodeNil()
  1617. return
  1618. }
  1619. ee, esep := e.e, e.hh.hasElemSeparators()
  1620. ee.WriteArrayStart(len(v))
  1621. for _, v2 := range v {
  1622. if esep {
  1623. ee.WriteArrayElem()
  1624. }
  1625. ee.EncodeUint(uint64(v2))
  1626. }
  1627. ee.WriteArrayEnd()
  1628. }
  1629. func (_ fastpathT) EncAsMapSliceUintV(v []uint, e *Encoder) {
  1630. ee, esep := e.e, e.hh.hasElemSeparators()
  1631. if len(v)%2 == 1 {
  1632. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  1633. return
  1634. }
  1635. ee.WriteMapStart(len(v) / 2)
  1636. for j, v2 := range v {
  1637. if esep {
  1638. if j%2 == 0 {
  1639. ee.WriteMapElemKey()
  1640. } else {
  1641. ee.WriteMapElemValue()
  1642. }
  1643. }
  1644. ee.EncodeUint(uint64(v2))
  1645. }
  1646. ee.WriteMapEnd()
  1647. }
  1648. func (e *Encoder) fastpathEncSliceUint16R(f *codecFnInfo, rv reflect.Value) {
  1649. if f.ti.mbs {
  1650. fastpathTV.EncAsMapSliceUint16V(rv2i(rv).([]uint16), e)
  1651. } else {
  1652. fastpathTV.EncSliceUint16V(rv2i(rv).([]uint16), e)
  1653. }
  1654. }
  1655. func (_ fastpathT) EncSliceUint16V(v []uint16, e *Encoder) {
  1656. if v == nil {
  1657. e.e.EncodeNil()
  1658. return
  1659. }
  1660. ee, esep := e.e, e.hh.hasElemSeparators()
  1661. ee.WriteArrayStart(len(v))
  1662. for _, v2 := range v {
  1663. if esep {
  1664. ee.WriteArrayElem()
  1665. }
  1666. ee.EncodeUint(uint64(v2))
  1667. }
  1668. ee.WriteArrayEnd()
  1669. }
  1670. func (_ fastpathT) EncAsMapSliceUint16V(v []uint16, e *Encoder) {
  1671. ee, esep := e.e, e.hh.hasElemSeparators()
  1672. if len(v)%2 == 1 {
  1673. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  1674. return
  1675. }
  1676. ee.WriteMapStart(len(v) / 2)
  1677. for j, v2 := range v {
  1678. if esep {
  1679. if j%2 == 0 {
  1680. ee.WriteMapElemKey()
  1681. } else {
  1682. ee.WriteMapElemValue()
  1683. }
  1684. }
  1685. ee.EncodeUint(uint64(v2))
  1686. }
  1687. ee.WriteMapEnd()
  1688. }
  1689. func (e *Encoder) fastpathEncSliceUint32R(f *codecFnInfo, rv reflect.Value) {
  1690. if f.ti.mbs {
  1691. fastpathTV.EncAsMapSliceUint32V(rv2i(rv).([]uint32), e)
  1692. } else {
  1693. fastpathTV.EncSliceUint32V(rv2i(rv).([]uint32), e)
  1694. }
  1695. }
  1696. func (_ fastpathT) EncSliceUint32V(v []uint32, e *Encoder) {
  1697. if v == nil {
  1698. e.e.EncodeNil()
  1699. return
  1700. }
  1701. ee, esep := e.e, e.hh.hasElemSeparators()
  1702. ee.WriteArrayStart(len(v))
  1703. for _, v2 := range v {
  1704. if esep {
  1705. ee.WriteArrayElem()
  1706. }
  1707. ee.EncodeUint(uint64(v2))
  1708. }
  1709. ee.WriteArrayEnd()
  1710. }
  1711. func (_ fastpathT) EncAsMapSliceUint32V(v []uint32, e *Encoder) {
  1712. ee, esep := e.e, e.hh.hasElemSeparators()
  1713. if len(v)%2 == 1 {
  1714. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  1715. return
  1716. }
  1717. ee.WriteMapStart(len(v) / 2)
  1718. for j, v2 := range v {
  1719. if esep {
  1720. if j%2 == 0 {
  1721. ee.WriteMapElemKey()
  1722. } else {
  1723. ee.WriteMapElemValue()
  1724. }
  1725. }
  1726. ee.EncodeUint(uint64(v2))
  1727. }
  1728. ee.WriteMapEnd()
  1729. }
  1730. func (e *Encoder) fastpathEncSliceUint64R(f *codecFnInfo, rv reflect.Value) {
  1731. if f.ti.mbs {
  1732. fastpathTV.EncAsMapSliceUint64V(rv2i(rv).([]uint64), e)
  1733. } else {
  1734. fastpathTV.EncSliceUint64V(rv2i(rv).([]uint64), e)
  1735. }
  1736. }
  1737. func (_ fastpathT) EncSliceUint64V(v []uint64, e *Encoder) {
  1738. if v == nil {
  1739. e.e.EncodeNil()
  1740. return
  1741. }
  1742. ee, esep := e.e, e.hh.hasElemSeparators()
  1743. ee.WriteArrayStart(len(v))
  1744. for _, v2 := range v {
  1745. if esep {
  1746. ee.WriteArrayElem()
  1747. }
  1748. ee.EncodeUint(uint64(v2))
  1749. }
  1750. ee.WriteArrayEnd()
  1751. }
  1752. func (_ fastpathT) EncAsMapSliceUint64V(v []uint64, e *Encoder) {
  1753. ee, esep := e.e, e.hh.hasElemSeparators()
  1754. if len(v)%2 == 1 {
  1755. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  1756. return
  1757. }
  1758. ee.WriteMapStart(len(v) / 2)
  1759. for j, v2 := range v {
  1760. if esep {
  1761. if j%2 == 0 {
  1762. ee.WriteMapElemKey()
  1763. } else {
  1764. ee.WriteMapElemValue()
  1765. }
  1766. }
  1767. ee.EncodeUint(uint64(v2))
  1768. }
  1769. ee.WriteMapEnd()
  1770. }
  1771. func (e *Encoder) fastpathEncSliceUintptrR(f *codecFnInfo, rv reflect.Value) {
  1772. if f.ti.mbs {
  1773. fastpathTV.EncAsMapSliceUintptrV(rv2i(rv).([]uintptr), e)
  1774. } else {
  1775. fastpathTV.EncSliceUintptrV(rv2i(rv).([]uintptr), e)
  1776. }
  1777. }
  1778. func (_ fastpathT) EncSliceUintptrV(v []uintptr, e *Encoder) {
  1779. if v == nil {
  1780. e.e.EncodeNil()
  1781. return
  1782. }
  1783. ee, esep := e.e, e.hh.hasElemSeparators()
  1784. ee.WriteArrayStart(len(v))
  1785. for _, v2 := range v {
  1786. if esep {
  1787. ee.WriteArrayElem()
  1788. }
  1789. e.encode(v2)
  1790. }
  1791. ee.WriteArrayEnd()
  1792. }
  1793. func (_ fastpathT) EncAsMapSliceUintptrV(v []uintptr, e *Encoder) {
  1794. ee, esep := e.e, e.hh.hasElemSeparators()
  1795. if len(v)%2 == 1 {
  1796. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  1797. return
  1798. }
  1799. ee.WriteMapStart(len(v) / 2)
  1800. for j, v2 := range v {
  1801. if esep {
  1802. if j%2 == 0 {
  1803. ee.WriteMapElemKey()
  1804. } else {
  1805. ee.WriteMapElemValue()
  1806. }
  1807. }
  1808. e.encode(v2)
  1809. }
  1810. ee.WriteMapEnd()
  1811. }
  1812. func (e *Encoder) fastpathEncSliceIntR(f *codecFnInfo, rv reflect.Value) {
  1813. if f.ti.mbs {
  1814. fastpathTV.EncAsMapSliceIntV(rv2i(rv).([]int), e)
  1815. } else {
  1816. fastpathTV.EncSliceIntV(rv2i(rv).([]int), e)
  1817. }
  1818. }
  1819. func (_ fastpathT) EncSliceIntV(v []int, e *Encoder) {
  1820. if v == nil {
  1821. e.e.EncodeNil()
  1822. return
  1823. }
  1824. ee, esep := e.e, e.hh.hasElemSeparators()
  1825. ee.WriteArrayStart(len(v))
  1826. for _, v2 := range v {
  1827. if esep {
  1828. ee.WriteArrayElem()
  1829. }
  1830. ee.EncodeInt(int64(v2))
  1831. }
  1832. ee.WriteArrayEnd()
  1833. }
  1834. func (_ fastpathT) EncAsMapSliceIntV(v []int, e *Encoder) {
  1835. ee, esep := e.e, e.hh.hasElemSeparators()
  1836. if len(v)%2 == 1 {
  1837. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  1838. return
  1839. }
  1840. ee.WriteMapStart(len(v) / 2)
  1841. for j, v2 := range v {
  1842. if esep {
  1843. if j%2 == 0 {
  1844. ee.WriteMapElemKey()
  1845. } else {
  1846. ee.WriteMapElemValue()
  1847. }
  1848. }
  1849. ee.EncodeInt(int64(v2))
  1850. }
  1851. ee.WriteMapEnd()
  1852. }
  1853. func (e *Encoder) fastpathEncSliceInt8R(f *codecFnInfo, rv reflect.Value) {
  1854. if f.ti.mbs {
  1855. fastpathTV.EncAsMapSliceInt8V(rv2i(rv).([]int8), e)
  1856. } else {
  1857. fastpathTV.EncSliceInt8V(rv2i(rv).([]int8), e)
  1858. }
  1859. }
  1860. func (_ fastpathT) EncSliceInt8V(v []int8, e *Encoder) {
  1861. if v == nil {
  1862. e.e.EncodeNil()
  1863. return
  1864. }
  1865. ee, esep := e.e, e.hh.hasElemSeparators()
  1866. ee.WriteArrayStart(len(v))
  1867. for _, v2 := range v {
  1868. if esep {
  1869. ee.WriteArrayElem()
  1870. }
  1871. ee.EncodeInt(int64(v2))
  1872. }
  1873. ee.WriteArrayEnd()
  1874. }
  1875. func (_ fastpathT) EncAsMapSliceInt8V(v []int8, e *Encoder) {
  1876. ee, esep := e.e, e.hh.hasElemSeparators()
  1877. if len(v)%2 == 1 {
  1878. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  1879. return
  1880. }
  1881. ee.WriteMapStart(len(v) / 2)
  1882. for j, v2 := range v {
  1883. if esep {
  1884. if j%2 == 0 {
  1885. ee.WriteMapElemKey()
  1886. } else {
  1887. ee.WriteMapElemValue()
  1888. }
  1889. }
  1890. ee.EncodeInt(int64(v2))
  1891. }
  1892. ee.WriteMapEnd()
  1893. }
  1894. func (e *Encoder) fastpathEncSliceInt16R(f *codecFnInfo, rv reflect.Value) {
  1895. if f.ti.mbs {
  1896. fastpathTV.EncAsMapSliceInt16V(rv2i(rv).([]int16), e)
  1897. } else {
  1898. fastpathTV.EncSliceInt16V(rv2i(rv).([]int16), e)
  1899. }
  1900. }
  1901. func (_ fastpathT) EncSliceInt16V(v []int16, e *Encoder) {
  1902. if v == nil {
  1903. e.e.EncodeNil()
  1904. return
  1905. }
  1906. ee, esep := e.e, e.hh.hasElemSeparators()
  1907. ee.WriteArrayStart(len(v))
  1908. for _, v2 := range v {
  1909. if esep {
  1910. ee.WriteArrayElem()
  1911. }
  1912. ee.EncodeInt(int64(v2))
  1913. }
  1914. ee.WriteArrayEnd()
  1915. }
  1916. func (_ fastpathT) EncAsMapSliceInt16V(v []int16, e *Encoder) {
  1917. ee, esep := e.e, e.hh.hasElemSeparators()
  1918. if len(v)%2 == 1 {
  1919. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  1920. return
  1921. }
  1922. ee.WriteMapStart(len(v) / 2)
  1923. for j, v2 := range v {
  1924. if esep {
  1925. if j%2 == 0 {
  1926. ee.WriteMapElemKey()
  1927. } else {
  1928. ee.WriteMapElemValue()
  1929. }
  1930. }
  1931. ee.EncodeInt(int64(v2))
  1932. }
  1933. ee.WriteMapEnd()
  1934. }
  1935. func (e *Encoder) fastpathEncSliceInt32R(f *codecFnInfo, rv reflect.Value) {
  1936. if f.ti.mbs {
  1937. fastpathTV.EncAsMapSliceInt32V(rv2i(rv).([]int32), e)
  1938. } else {
  1939. fastpathTV.EncSliceInt32V(rv2i(rv).([]int32), e)
  1940. }
  1941. }
  1942. func (_ fastpathT) EncSliceInt32V(v []int32, e *Encoder) {
  1943. if v == nil {
  1944. e.e.EncodeNil()
  1945. return
  1946. }
  1947. ee, esep := e.e, e.hh.hasElemSeparators()
  1948. ee.WriteArrayStart(len(v))
  1949. for _, v2 := range v {
  1950. if esep {
  1951. ee.WriteArrayElem()
  1952. }
  1953. ee.EncodeInt(int64(v2))
  1954. }
  1955. ee.WriteArrayEnd()
  1956. }
  1957. func (_ fastpathT) EncAsMapSliceInt32V(v []int32, e *Encoder) {
  1958. ee, esep := e.e, e.hh.hasElemSeparators()
  1959. if len(v)%2 == 1 {
  1960. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  1961. return
  1962. }
  1963. ee.WriteMapStart(len(v) / 2)
  1964. for j, v2 := range v {
  1965. if esep {
  1966. if j%2 == 0 {
  1967. ee.WriteMapElemKey()
  1968. } else {
  1969. ee.WriteMapElemValue()
  1970. }
  1971. }
  1972. ee.EncodeInt(int64(v2))
  1973. }
  1974. ee.WriteMapEnd()
  1975. }
  1976. func (e *Encoder) fastpathEncSliceInt64R(f *codecFnInfo, rv reflect.Value) {
  1977. if f.ti.mbs {
  1978. fastpathTV.EncAsMapSliceInt64V(rv2i(rv).([]int64), e)
  1979. } else {
  1980. fastpathTV.EncSliceInt64V(rv2i(rv).([]int64), e)
  1981. }
  1982. }
  1983. func (_ fastpathT) EncSliceInt64V(v []int64, e *Encoder) {
  1984. if v == nil {
  1985. e.e.EncodeNil()
  1986. return
  1987. }
  1988. ee, esep := e.e, e.hh.hasElemSeparators()
  1989. ee.WriteArrayStart(len(v))
  1990. for _, v2 := range v {
  1991. if esep {
  1992. ee.WriteArrayElem()
  1993. }
  1994. ee.EncodeInt(int64(v2))
  1995. }
  1996. ee.WriteArrayEnd()
  1997. }
  1998. func (_ fastpathT) EncAsMapSliceInt64V(v []int64, e *Encoder) {
  1999. ee, esep := e.e, e.hh.hasElemSeparators()
  2000. if len(v)%2 == 1 {
  2001. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  2002. return
  2003. }
  2004. ee.WriteMapStart(len(v) / 2)
  2005. for j, v2 := range v {
  2006. if esep {
  2007. if j%2 == 0 {
  2008. ee.WriteMapElemKey()
  2009. } else {
  2010. ee.WriteMapElemValue()
  2011. }
  2012. }
  2013. ee.EncodeInt(int64(v2))
  2014. }
  2015. ee.WriteMapEnd()
  2016. }
  2017. func (e *Encoder) fastpathEncSliceBoolR(f *codecFnInfo, rv reflect.Value) {
  2018. if f.ti.mbs {
  2019. fastpathTV.EncAsMapSliceBoolV(rv2i(rv).([]bool), e)
  2020. } else {
  2021. fastpathTV.EncSliceBoolV(rv2i(rv).([]bool), e)
  2022. }
  2023. }
  2024. func (_ fastpathT) EncSliceBoolV(v []bool, e *Encoder) {
  2025. if v == nil {
  2026. e.e.EncodeNil()
  2027. return
  2028. }
  2029. ee, esep := e.e, e.hh.hasElemSeparators()
  2030. ee.WriteArrayStart(len(v))
  2031. for _, v2 := range v {
  2032. if esep {
  2033. ee.WriteArrayElem()
  2034. }
  2035. ee.EncodeBool(v2)
  2036. }
  2037. ee.WriteArrayEnd()
  2038. }
  2039. func (_ fastpathT) EncAsMapSliceBoolV(v []bool, e *Encoder) {
  2040. ee, esep := e.e, e.hh.hasElemSeparators()
  2041. if len(v)%2 == 1 {
  2042. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  2043. return
  2044. }
  2045. ee.WriteMapStart(len(v) / 2)
  2046. for j, v2 := range v {
  2047. if esep {
  2048. if j%2 == 0 {
  2049. ee.WriteMapElemKey()
  2050. } else {
  2051. ee.WriteMapElemValue()
  2052. }
  2053. }
  2054. ee.EncodeBool(v2)
  2055. }
  2056. ee.WriteMapEnd()
  2057. }
  2058. func (e *Encoder) fastpathEncMapIntfIntfR(f *codecFnInfo, rv reflect.Value) {
  2059. fastpathTV.EncMapIntfIntfV(rv2i(rv).(map[interface{}]interface{}), e)
  2060. }
  2061. func (_ fastpathT) EncMapIntfIntfV(v map[interface{}]interface{}, e *Encoder) {
  2062. if v == nil {
  2063. e.e.EncodeNil()
  2064. return
  2065. }
  2066. ee, esep := e.e, e.hh.hasElemSeparators()
  2067. ee.WriteMapStart(len(v))
  2068. if e.h.Canonical {
  2069. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2070. e2 := NewEncoderBytes(&mksv, e.hh)
  2071. v2 := make([]bytesI, len(v))
  2072. var i, l int
  2073. var vp *bytesI
  2074. for k2, _ := range v {
  2075. l = len(mksv)
  2076. e2.MustEncode(k2)
  2077. vp = &v2[i]
  2078. vp.v = mksv[l:]
  2079. vp.i = k2
  2080. i++
  2081. }
  2082. sort.Sort(bytesISlice(v2))
  2083. for j := range v2 {
  2084. if esep {
  2085. ee.WriteMapElemKey()
  2086. }
  2087. e.asis(v2[j].v)
  2088. if esep {
  2089. ee.WriteMapElemValue()
  2090. }
  2091. e.encode(v[v2[j].i])
  2092. }
  2093. } else {
  2094. for k2, v2 := range v {
  2095. if esep {
  2096. ee.WriteMapElemKey()
  2097. }
  2098. e.encode(k2)
  2099. if esep {
  2100. ee.WriteMapElemValue()
  2101. }
  2102. e.encode(v2)
  2103. }
  2104. }
  2105. ee.WriteMapEnd()
  2106. }
  2107. func (e *Encoder) fastpathEncMapIntfStringR(f *codecFnInfo, rv reflect.Value) {
  2108. fastpathTV.EncMapIntfStringV(rv2i(rv).(map[interface{}]string), e)
  2109. }
  2110. func (_ fastpathT) EncMapIntfStringV(v map[interface{}]string, e *Encoder) {
  2111. if v == nil {
  2112. e.e.EncodeNil()
  2113. return
  2114. }
  2115. ee, esep := e.e, e.hh.hasElemSeparators()
  2116. ee.WriteMapStart(len(v))
  2117. if e.h.Canonical {
  2118. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2119. e2 := NewEncoderBytes(&mksv, e.hh)
  2120. v2 := make([]bytesI, len(v))
  2121. var i, l int
  2122. var vp *bytesI
  2123. for k2, _ := range v {
  2124. l = len(mksv)
  2125. e2.MustEncode(k2)
  2126. vp = &v2[i]
  2127. vp.v = mksv[l:]
  2128. vp.i = k2
  2129. i++
  2130. }
  2131. sort.Sort(bytesISlice(v2))
  2132. for j := range v2 {
  2133. if esep {
  2134. ee.WriteMapElemKey()
  2135. }
  2136. e.asis(v2[j].v)
  2137. if esep {
  2138. ee.WriteMapElemValue()
  2139. }
  2140. e.encode(v[v2[j].i])
  2141. }
  2142. } else {
  2143. for k2, v2 := range v {
  2144. if esep {
  2145. ee.WriteMapElemKey()
  2146. }
  2147. e.encode(k2)
  2148. if esep {
  2149. ee.WriteMapElemValue()
  2150. }
  2151. ee.EncodeString(cUTF8, v2)
  2152. }
  2153. }
  2154. ee.WriteMapEnd()
  2155. }
  2156. func (e *Encoder) fastpathEncMapIntfUintR(f *codecFnInfo, rv reflect.Value) {
  2157. fastpathTV.EncMapIntfUintV(rv2i(rv).(map[interface{}]uint), e)
  2158. }
  2159. func (_ fastpathT) EncMapIntfUintV(v map[interface{}]uint, e *Encoder) {
  2160. if v == nil {
  2161. e.e.EncodeNil()
  2162. return
  2163. }
  2164. ee, esep := e.e, e.hh.hasElemSeparators()
  2165. ee.WriteMapStart(len(v))
  2166. if e.h.Canonical {
  2167. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2168. e2 := NewEncoderBytes(&mksv, e.hh)
  2169. v2 := make([]bytesI, len(v))
  2170. var i, l int
  2171. var vp *bytesI
  2172. for k2, _ := range v {
  2173. l = len(mksv)
  2174. e2.MustEncode(k2)
  2175. vp = &v2[i]
  2176. vp.v = mksv[l:]
  2177. vp.i = k2
  2178. i++
  2179. }
  2180. sort.Sort(bytesISlice(v2))
  2181. for j := range v2 {
  2182. if esep {
  2183. ee.WriteMapElemKey()
  2184. }
  2185. e.asis(v2[j].v)
  2186. if esep {
  2187. ee.WriteMapElemValue()
  2188. }
  2189. e.encode(v[v2[j].i])
  2190. }
  2191. } else {
  2192. for k2, v2 := range v {
  2193. if esep {
  2194. ee.WriteMapElemKey()
  2195. }
  2196. e.encode(k2)
  2197. if esep {
  2198. ee.WriteMapElemValue()
  2199. }
  2200. ee.EncodeUint(uint64(v2))
  2201. }
  2202. }
  2203. ee.WriteMapEnd()
  2204. }
  2205. func (e *Encoder) fastpathEncMapIntfUint8R(f *codecFnInfo, rv reflect.Value) {
  2206. fastpathTV.EncMapIntfUint8V(rv2i(rv).(map[interface{}]uint8), e)
  2207. }
  2208. func (_ fastpathT) EncMapIntfUint8V(v map[interface{}]uint8, e *Encoder) {
  2209. if v == nil {
  2210. e.e.EncodeNil()
  2211. return
  2212. }
  2213. ee, esep := e.e, e.hh.hasElemSeparators()
  2214. ee.WriteMapStart(len(v))
  2215. if e.h.Canonical {
  2216. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2217. e2 := NewEncoderBytes(&mksv, e.hh)
  2218. v2 := make([]bytesI, len(v))
  2219. var i, l int
  2220. var vp *bytesI
  2221. for k2, _ := range v {
  2222. l = len(mksv)
  2223. e2.MustEncode(k2)
  2224. vp = &v2[i]
  2225. vp.v = mksv[l:]
  2226. vp.i = k2
  2227. i++
  2228. }
  2229. sort.Sort(bytesISlice(v2))
  2230. for j := range v2 {
  2231. if esep {
  2232. ee.WriteMapElemKey()
  2233. }
  2234. e.asis(v2[j].v)
  2235. if esep {
  2236. ee.WriteMapElemValue()
  2237. }
  2238. e.encode(v[v2[j].i])
  2239. }
  2240. } else {
  2241. for k2, v2 := range v {
  2242. if esep {
  2243. ee.WriteMapElemKey()
  2244. }
  2245. e.encode(k2)
  2246. if esep {
  2247. ee.WriteMapElemValue()
  2248. }
  2249. ee.EncodeUint(uint64(v2))
  2250. }
  2251. }
  2252. ee.WriteMapEnd()
  2253. }
  2254. func (e *Encoder) fastpathEncMapIntfUint16R(f *codecFnInfo, rv reflect.Value) {
  2255. fastpathTV.EncMapIntfUint16V(rv2i(rv).(map[interface{}]uint16), e)
  2256. }
  2257. func (_ fastpathT) EncMapIntfUint16V(v map[interface{}]uint16, e *Encoder) {
  2258. if v == nil {
  2259. e.e.EncodeNil()
  2260. return
  2261. }
  2262. ee, esep := e.e, e.hh.hasElemSeparators()
  2263. ee.WriteMapStart(len(v))
  2264. if e.h.Canonical {
  2265. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2266. e2 := NewEncoderBytes(&mksv, e.hh)
  2267. v2 := make([]bytesI, len(v))
  2268. var i, l int
  2269. var vp *bytesI
  2270. for k2, _ := range v {
  2271. l = len(mksv)
  2272. e2.MustEncode(k2)
  2273. vp = &v2[i]
  2274. vp.v = mksv[l:]
  2275. vp.i = k2
  2276. i++
  2277. }
  2278. sort.Sort(bytesISlice(v2))
  2279. for j := range v2 {
  2280. if esep {
  2281. ee.WriteMapElemKey()
  2282. }
  2283. e.asis(v2[j].v)
  2284. if esep {
  2285. ee.WriteMapElemValue()
  2286. }
  2287. e.encode(v[v2[j].i])
  2288. }
  2289. } else {
  2290. for k2, v2 := range v {
  2291. if esep {
  2292. ee.WriteMapElemKey()
  2293. }
  2294. e.encode(k2)
  2295. if esep {
  2296. ee.WriteMapElemValue()
  2297. }
  2298. ee.EncodeUint(uint64(v2))
  2299. }
  2300. }
  2301. ee.WriteMapEnd()
  2302. }
  2303. func (e *Encoder) fastpathEncMapIntfUint32R(f *codecFnInfo, rv reflect.Value) {
  2304. fastpathTV.EncMapIntfUint32V(rv2i(rv).(map[interface{}]uint32), e)
  2305. }
  2306. func (_ fastpathT) EncMapIntfUint32V(v map[interface{}]uint32, e *Encoder) {
  2307. if v == nil {
  2308. e.e.EncodeNil()
  2309. return
  2310. }
  2311. ee, esep := e.e, e.hh.hasElemSeparators()
  2312. ee.WriteMapStart(len(v))
  2313. if e.h.Canonical {
  2314. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2315. e2 := NewEncoderBytes(&mksv, e.hh)
  2316. v2 := make([]bytesI, len(v))
  2317. var i, l int
  2318. var vp *bytesI
  2319. for k2, _ := range v {
  2320. l = len(mksv)
  2321. e2.MustEncode(k2)
  2322. vp = &v2[i]
  2323. vp.v = mksv[l:]
  2324. vp.i = k2
  2325. i++
  2326. }
  2327. sort.Sort(bytesISlice(v2))
  2328. for j := range v2 {
  2329. if esep {
  2330. ee.WriteMapElemKey()
  2331. }
  2332. e.asis(v2[j].v)
  2333. if esep {
  2334. ee.WriteMapElemValue()
  2335. }
  2336. e.encode(v[v2[j].i])
  2337. }
  2338. } else {
  2339. for k2, v2 := range v {
  2340. if esep {
  2341. ee.WriteMapElemKey()
  2342. }
  2343. e.encode(k2)
  2344. if esep {
  2345. ee.WriteMapElemValue()
  2346. }
  2347. ee.EncodeUint(uint64(v2))
  2348. }
  2349. }
  2350. ee.WriteMapEnd()
  2351. }
  2352. func (e *Encoder) fastpathEncMapIntfUint64R(f *codecFnInfo, rv reflect.Value) {
  2353. fastpathTV.EncMapIntfUint64V(rv2i(rv).(map[interface{}]uint64), e)
  2354. }
  2355. func (_ fastpathT) EncMapIntfUint64V(v map[interface{}]uint64, e *Encoder) {
  2356. if v == nil {
  2357. e.e.EncodeNil()
  2358. return
  2359. }
  2360. ee, esep := e.e, e.hh.hasElemSeparators()
  2361. ee.WriteMapStart(len(v))
  2362. if e.h.Canonical {
  2363. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2364. e2 := NewEncoderBytes(&mksv, e.hh)
  2365. v2 := make([]bytesI, len(v))
  2366. var i, l int
  2367. var vp *bytesI
  2368. for k2, _ := range v {
  2369. l = len(mksv)
  2370. e2.MustEncode(k2)
  2371. vp = &v2[i]
  2372. vp.v = mksv[l:]
  2373. vp.i = k2
  2374. i++
  2375. }
  2376. sort.Sort(bytesISlice(v2))
  2377. for j := range v2 {
  2378. if esep {
  2379. ee.WriteMapElemKey()
  2380. }
  2381. e.asis(v2[j].v)
  2382. if esep {
  2383. ee.WriteMapElemValue()
  2384. }
  2385. e.encode(v[v2[j].i])
  2386. }
  2387. } else {
  2388. for k2, v2 := range v {
  2389. if esep {
  2390. ee.WriteMapElemKey()
  2391. }
  2392. e.encode(k2)
  2393. if esep {
  2394. ee.WriteMapElemValue()
  2395. }
  2396. ee.EncodeUint(uint64(v2))
  2397. }
  2398. }
  2399. ee.WriteMapEnd()
  2400. }
  2401. func (e *Encoder) fastpathEncMapIntfUintptrR(f *codecFnInfo, rv reflect.Value) {
  2402. fastpathTV.EncMapIntfUintptrV(rv2i(rv).(map[interface{}]uintptr), e)
  2403. }
  2404. func (_ fastpathT) EncMapIntfUintptrV(v map[interface{}]uintptr, e *Encoder) {
  2405. if v == nil {
  2406. e.e.EncodeNil()
  2407. return
  2408. }
  2409. ee, esep := e.e, e.hh.hasElemSeparators()
  2410. ee.WriteMapStart(len(v))
  2411. if e.h.Canonical {
  2412. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2413. e2 := NewEncoderBytes(&mksv, e.hh)
  2414. v2 := make([]bytesI, len(v))
  2415. var i, l int
  2416. var vp *bytesI
  2417. for k2, _ := range v {
  2418. l = len(mksv)
  2419. e2.MustEncode(k2)
  2420. vp = &v2[i]
  2421. vp.v = mksv[l:]
  2422. vp.i = k2
  2423. i++
  2424. }
  2425. sort.Sort(bytesISlice(v2))
  2426. for j := range v2 {
  2427. if esep {
  2428. ee.WriteMapElemKey()
  2429. }
  2430. e.asis(v2[j].v)
  2431. if esep {
  2432. ee.WriteMapElemValue()
  2433. }
  2434. e.encode(v[v2[j].i])
  2435. }
  2436. } else {
  2437. for k2, v2 := range v {
  2438. if esep {
  2439. ee.WriteMapElemKey()
  2440. }
  2441. e.encode(k2)
  2442. if esep {
  2443. ee.WriteMapElemValue()
  2444. }
  2445. e.encode(v2)
  2446. }
  2447. }
  2448. ee.WriteMapEnd()
  2449. }
  2450. func (e *Encoder) fastpathEncMapIntfIntR(f *codecFnInfo, rv reflect.Value) {
  2451. fastpathTV.EncMapIntfIntV(rv2i(rv).(map[interface{}]int), e)
  2452. }
  2453. func (_ fastpathT) EncMapIntfIntV(v map[interface{}]int, e *Encoder) {
  2454. if v == nil {
  2455. e.e.EncodeNil()
  2456. return
  2457. }
  2458. ee, esep := e.e, e.hh.hasElemSeparators()
  2459. ee.WriteMapStart(len(v))
  2460. if e.h.Canonical {
  2461. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2462. e2 := NewEncoderBytes(&mksv, e.hh)
  2463. v2 := make([]bytesI, len(v))
  2464. var i, l int
  2465. var vp *bytesI
  2466. for k2, _ := range v {
  2467. l = len(mksv)
  2468. e2.MustEncode(k2)
  2469. vp = &v2[i]
  2470. vp.v = mksv[l:]
  2471. vp.i = k2
  2472. i++
  2473. }
  2474. sort.Sort(bytesISlice(v2))
  2475. for j := range v2 {
  2476. if esep {
  2477. ee.WriteMapElemKey()
  2478. }
  2479. e.asis(v2[j].v)
  2480. if esep {
  2481. ee.WriteMapElemValue()
  2482. }
  2483. e.encode(v[v2[j].i])
  2484. }
  2485. } else {
  2486. for k2, v2 := range v {
  2487. if esep {
  2488. ee.WriteMapElemKey()
  2489. }
  2490. e.encode(k2)
  2491. if esep {
  2492. ee.WriteMapElemValue()
  2493. }
  2494. ee.EncodeInt(int64(v2))
  2495. }
  2496. }
  2497. ee.WriteMapEnd()
  2498. }
  2499. func (e *Encoder) fastpathEncMapIntfInt8R(f *codecFnInfo, rv reflect.Value) {
  2500. fastpathTV.EncMapIntfInt8V(rv2i(rv).(map[interface{}]int8), e)
  2501. }
  2502. func (_ fastpathT) EncMapIntfInt8V(v map[interface{}]int8, e *Encoder) {
  2503. if v == nil {
  2504. e.e.EncodeNil()
  2505. return
  2506. }
  2507. ee, esep := e.e, e.hh.hasElemSeparators()
  2508. ee.WriteMapStart(len(v))
  2509. if e.h.Canonical {
  2510. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2511. e2 := NewEncoderBytes(&mksv, e.hh)
  2512. v2 := make([]bytesI, len(v))
  2513. var i, l int
  2514. var vp *bytesI
  2515. for k2, _ := range v {
  2516. l = len(mksv)
  2517. e2.MustEncode(k2)
  2518. vp = &v2[i]
  2519. vp.v = mksv[l:]
  2520. vp.i = k2
  2521. i++
  2522. }
  2523. sort.Sort(bytesISlice(v2))
  2524. for j := range v2 {
  2525. if esep {
  2526. ee.WriteMapElemKey()
  2527. }
  2528. e.asis(v2[j].v)
  2529. if esep {
  2530. ee.WriteMapElemValue()
  2531. }
  2532. e.encode(v[v2[j].i])
  2533. }
  2534. } else {
  2535. for k2, v2 := range v {
  2536. if esep {
  2537. ee.WriteMapElemKey()
  2538. }
  2539. e.encode(k2)
  2540. if esep {
  2541. ee.WriteMapElemValue()
  2542. }
  2543. ee.EncodeInt(int64(v2))
  2544. }
  2545. }
  2546. ee.WriteMapEnd()
  2547. }
  2548. func (e *Encoder) fastpathEncMapIntfInt16R(f *codecFnInfo, rv reflect.Value) {
  2549. fastpathTV.EncMapIntfInt16V(rv2i(rv).(map[interface{}]int16), e)
  2550. }
  2551. func (_ fastpathT) EncMapIntfInt16V(v map[interface{}]int16, e *Encoder) {
  2552. if v == nil {
  2553. e.e.EncodeNil()
  2554. return
  2555. }
  2556. ee, esep := e.e, e.hh.hasElemSeparators()
  2557. ee.WriteMapStart(len(v))
  2558. if e.h.Canonical {
  2559. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2560. e2 := NewEncoderBytes(&mksv, e.hh)
  2561. v2 := make([]bytesI, len(v))
  2562. var i, l int
  2563. var vp *bytesI
  2564. for k2, _ := range v {
  2565. l = len(mksv)
  2566. e2.MustEncode(k2)
  2567. vp = &v2[i]
  2568. vp.v = mksv[l:]
  2569. vp.i = k2
  2570. i++
  2571. }
  2572. sort.Sort(bytesISlice(v2))
  2573. for j := range v2 {
  2574. if esep {
  2575. ee.WriteMapElemKey()
  2576. }
  2577. e.asis(v2[j].v)
  2578. if esep {
  2579. ee.WriteMapElemValue()
  2580. }
  2581. e.encode(v[v2[j].i])
  2582. }
  2583. } else {
  2584. for k2, v2 := range v {
  2585. if esep {
  2586. ee.WriteMapElemKey()
  2587. }
  2588. e.encode(k2)
  2589. if esep {
  2590. ee.WriteMapElemValue()
  2591. }
  2592. ee.EncodeInt(int64(v2))
  2593. }
  2594. }
  2595. ee.WriteMapEnd()
  2596. }
  2597. func (e *Encoder) fastpathEncMapIntfInt32R(f *codecFnInfo, rv reflect.Value) {
  2598. fastpathTV.EncMapIntfInt32V(rv2i(rv).(map[interface{}]int32), e)
  2599. }
  2600. func (_ fastpathT) EncMapIntfInt32V(v map[interface{}]int32, e *Encoder) {
  2601. if v == nil {
  2602. e.e.EncodeNil()
  2603. return
  2604. }
  2605. ee, esep := e.e, e.hh.hasElemSeparators()
  2606. ee.WriteMapStart(len(v))
  2607. if e.h.Canonical {
  2608. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2609. e2 := NewEncoderBytes(&mksv, e.hh)
  2610. v2 := make([]bytesI, len(v))
  2611. var i, l int
  2612. var vp *bytesI
  2613. for k2, _ := range v {
  2614. l = len(mksv)
  2615. e2.MustEncode(k2)
  2616. vp = &v2[i]
  2617. vp.v = mksv[l:]
  2618. vp.i = k2
  2619. i++
  2620. }
  2621. sort.Sort(bytesISlice(v2))
  2622. for j := range v2 {
  2623. if esep {
  2624. ee.WriteMapElemKey()
  2625. }
  2626. e.asis(v2[j].v)
  2627. if esep {
  2628. ee.WriteMapElemValue()
  2629. }
  2630. e.encode(v[v2[j].i])
  2631. }
  2632. } else {
  2633. for k2, v2 := range v {
  2634. if esep {
  2635. ee.WriteMapElemKey()
  2636. }
  2637. e.encode(k2)
  2638. if esep {
  2639. ee.WriteMapElemValue()
  2640. }
  2641. ee.EncodeInt(int64(v2))
  2642. }
  2643. }
  2644. ee.WriteMapEnd()
  2645. }
  2646. func (e *Encoder) fastpathEncMapIntfInt64R(f *codecFnInfo, rv reflect.Value) {
  2647. fastpathTV.EncMapIntfInt64V(rv2i(rv).(map[interface{}]int64), e)
  2648. }
  2649. func (_ fastpathT) EncMapIntfInt64V(v map[interface{}]int64, e *Encoder) {
  2650. if v == nil {
  2651. e.e.EncodeNil()
  2652. return
  2653. }
  2654. ee, esep := e.e, e.hh.hasElemSeparators()
  2655. ee.WriteMapStart(len(v))
  2656. if e.h.Canonical {
  2657. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2658. e2 := NewEncoderBytes(&mksv, e.hh)
  2659. v2 := make([]bytesI, len(v))
  2660. var i, l int
  2661. var vp *bytesI
  2662. for k2, _ := range v {
  2663. l = len(mksv)
  2664. e2.MustEncode(k2)
  2665. vp = &v2[i]
  2666. vp.v = mksv[l:]
  2667. vp.i = k2
  2668. i++
  2669. }
  2670. sort.Sort(bytesISlice(v2))
  2671. for j := range v2 {
  2672. if esep {
  2673. ee.WriteMapElemKey()
  2674. }
  2675. e.asis(v2[j].v)
  2676. if esep {
  2677. ee.WriteMapElemValue()
  2678. }
  2679. e.encode(v[v2[j].i])
  2680. }
  2681. } else {
  2682. for k2, v2 := range v {
  2683. if esep {
  2684. ee.WriteMapElemKey()
  2685. }
  2686. e.encode(k2)
  2687. if esep {
  2688. ee.WriteMapElemValue()
  2689. }
  2690. ee.EncodeInt(int64(v2))
  2691. }
  2692. }
  2693. ee.WriteMapEnd()
  2694. }
  2695. func (e *Encoder) fastpathEncMapIntfFloat32R(f *codecFnInfo, rv reflect.Value) {
  2696. fastpathTV.EncMapIntfFloat32V(rv2i(rv).(map[interface{}]float32), e)
  2697. }
  2698. func (_ fastpathT) EncMapIntfFloat32V(v map[interface{}]float32, e *Encoder) {
  2699. if v == nil {
  2700. e.e.EncodeNil()
  2701. return
  2702. }
  2703. ee, esep := e.e, e.hh.hasElemSeparators()
  2704. ee.WriteMapStart(len(v))
  2705. if e.h.Canonical {
  2706. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2707. e2 := NewEncoderBytes(&mksv, e.hh)
  2708. v2 := make([]bytesI, len(v))
  2709. var i, l int
  2710. var vp *bytesI
  2711. for k2, _ := range v {
  2712. l = len(mksv)
  2713. e2.MustEncode(k2)
  2714. vp = &v2[i]
  2715. vp.v = mksv[l:]
  2716. vp.i = k2
  2717. i++
  2718. }
  2719. sort.Sort(bytesISlice(v2))
  2720. for j := range v2 {
  2721. if esep {
  2722. ee.WriteMapElemKey()
  2723. }
  2724. e.asis(v2[j].v)
  2725. if esep {
  2726. ee.WriteMapElemValue()
  2727. }
  2728. e.encode(v[v2[j].i])
  2729. }
  2730. } else {
  2731. for k2, v2 := range v {
  2732. if esep {
  2733. ee.WriteMapElemKey()
  2734. }
  2735. e.encode(k2)
  2736. if esep {
  2737. ee.WriteMapElemValue()
  2738. }
  2739. ee.EncodeFloat32(v2)
  2740. }
  2741. }
  2742. ee.WriteMapEnd()
  2743. }
  2744. func (e *Encoder) fastpathEncMapIntfFloat64R(f *codecFnInfo, rv reflect.Value) {
  2745. fastpathTV.EncMapIntfFloat64V(rv2i(rv).(map[interface{}]float64), e)
  2746. }
  2747. func (_ fastpathT) EncMapIntfFloat64V(v map[interface{}]float64, e *Encoder) {
  2748. if v == nil {
  2749. e.e.EncodeNil()
  2750. return
  2751. }
  2752. ee, esep := e.e, e.hh.hasElemSeparators()
  2753. ee.WriteMapStart(len(v))
  2754. if e.h.Canonical {
  2755. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2756. e2 := NewEncoderBytes(&mksv, e.hh)
  2757. v2 := make([]bytesI, len(v))
  2758. var i, l int
  2759. var vp *bytesI
  2760. for k2, _ := range v {
  2761. l = len(mksv)
  2762. e2.MustEncode(k2)
  2763. vp = &v2[i]
  2764. vp.v = mksv[l:]
  2765. vp.i = k2
  2766. i++
  2767. }
  2768. sort.Sort(bytesISlice(v2))
  2769. for j := range v2 {
  2770. if esep {
  2771. ee.WriteMapElemKey()
  2772. }
  2773. e.asis(v2[j].v)
  2774. if esep {
  2775. ee.WriteMapElemValue()
  2776. }
  2777. e.encode(v[v2[j].i])
  2778. }
  2779. } else {
  2780. for k2, v2 := range v {
  2781. if esep {
  2782. ee.WriteMapElemKey()
  2783. }
  2784. e.encode(k2)
  2785. if esep {
  2786. ee.WriteMapElemValue()
  2787. }
  2788. ee.EncodeFloat64(v2)
  2789. }
  2790. }
  2791. ee.WriteMapEnd()
  2792. }
  2793. func (e *Encoder) fastpathEncMapIntfBoolR(f *codecFnInfo, rv reflect.Value) {
  2794. fastpathTV.EncMapIntfBoolV(rv2i(rv).(map[interface{}]bool), e)
  2795. }
  2796. func (_ fastpathT) EncMapIntfBoolV(v map[interface{}]bool, e *Encoder) {
  2797. if v == nil {
  2798. e.e.EncodeNil()
  2799. return
  2800. }
  2801. ee, esep := e.e, e.hh.hasElemSeparators()
  2802. ee.WriteMapStart(len(v))
  2803. if e.h.Canonical {
  2804. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2805. e2 := NewEncoderBytes(&mksv, e.hh)
  2806. v2 := make([]bytesI, len(v))
  2807. var i, l int
  2808. var vp *bytesI
  2809. for k2, _ := range v {
  2810. l = len(mksv)
  2811. e2.MustEncode(k2)
  2812. vp = &v2[i]
  2813. vp.v = mksv[l:]
  2814. vp.i = k2
  2815. i++
  2816. }
  2817. sort.Sort(bytesISlice(v2))
  2818. for j := range v2 {
  2819. if esep {
  2820. ee.WriteMapElemKey()
  2821. }
  2822. e.asis(v2[j].v)
  2823. if esep {
  2824. ee.WriteMapElemValue()
  2825. }
  2826. e.encode(v[v2[j].i])
  2827. }
  2828. } else {
  2829. for k2, v2 := range v {
  2830. if esep {
  2831. ee.WriteMapElemKey()
  2832. }
  2833. e.encode(k2)
  2834. if esep {
  2835. ee.WriteMapElemValue()
  2836. }
  2837. ee.EncodeBool(v2)
  2838. }
  2839. }
  2840. ee.WriteMapEnd()
  2841. }
  2842. func (e *Encoder) fastpathEncMapStringIntfR(f *codecFnInfo, rv reflect.Value) {
  2843. fastpathTV.EncMapStringIntfV(rv2i(rv).(map[string]interface{}), e)
  2844. }
  2845. func (_ fastpathT) EncMapStringIntfV(v map[string]interface{}, e *Encoder) {
  2846. if v == nil {
  2847. e.e.EncodeNil()
  2848. return
  2849. }
  2850. ee, esep := e.e, e.hh.hasElemSeparators()
  2851. ee.WriteMapStart(len(v))
  2852. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  2853. if e.h.Canonical {
  2854. v2 := make([]string, len(v))
  2855. var i int
  2856. for k, _ := range v {
  2857. v2[i] = string(k)
  2858. i++
  2859. }
  2860. sort.Sort(stringSlice(v2))
  2861. for _, k2 := range v2 {
  2862. if esep {
  2863. ee.WriteMapElemKey()
  2864. }
  2865. if asSymbols {
  2866. ee.EncodeSymbol(k2)
  2867. } else {
  2868. ee.EncodeString(cUTF8, k2)
  2869. }
  2870. if esep {
  2871. ee.WriteMapElemValue()
  2872. }
  2873. e.encode(v[string(k2)])
  2874. }
  2875. } else {
  2876. for k2, v2 := range v {
  2877. if esep {
  2878. ee.WriteMapElemKey()
  2879. }
  2880. if asSymbols {
  2881. ee.EncodeSymbol(k2)
  2882. } else {
  2883. ee.EncodeString(cUTF8, k2)
  2884. }
  2885. if esep {
  2886. ee.WriteMapElemValue()
  2887. }
  2888. e.encode(v2)
  2889. }
  2890. }
  2891. ee.WriteMapEnd()
  2892. }
  2893. func (e *Encoder) fastpathEncMapStringStringR(f *codecFnInfo, rv reflect.Value) {
  2894. fastpathTV.EncMapStringStringV(rv2i(rv).(map[string]string), e)
  2895. }
  2896. func (_ fastpathT) EncMapStringStringV(v map[string]string, e *Encoder) {
  2897. if v == nil {
  2898. e.e.EncodeNil()
  2899. return
  2900. }
  2901. ee, esep := e.e, e.hh.hasElemSeparators()
  2902. ee.WriteMapStart(len(v))
  2903. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  2904. if e.h.Canonical {
  2905. v2 := make([]string, len(v))
  2906. var i int
  2907. for k, _ := range v {
  2908. v2[i] = string(k)
  2909. i++
  2910. }
  2911. sort.Sort(stringSlice(v2))
  2912. for _, k2 := range v2 {
  2913. if esep {
  2914. ee.WriteMapElemKey()
  2915. }
  2916. if asSymbols {
  2917. ee.EncodeSymbol(k2)
  2918. } else {
  2919. ee.EncodeString(cUTF8, k2)
  2920. }
  2921. if esep {
  2922. ee.WriteMapElemValue()
  2923. }
  2924. ee.EncodeString(cUTF8, v[string(k2)])
  2925. }
  2926. } else {
  2927. for k2, v2 := range v {
  2928. if esep {
  2929. ee.WriteMapElemKey()
  2930. }
  2931. if asSymbols {
  2932. ee.EncodeSymbol(k2)
  2933. } else {
  2934. ee.EncodeString(cUTF8, k2)
  2935. }
  2936. if esep {
  2937. ee.WriteMapElemValue()
  2938. }
  2939. ee.EncodeString(cUTF8, v2)
  2940. }
  2941. }
  2942. ee.WriteMapEnd()
  2943. }
  2944. func (e *Encoder) fastpathEncMapStringUintR(f *codecFnInfo, rv reflect.Value) {
  2945. fastpathTV.EncMapStringUintV(rv2i(rv).(map[string]uint), e)
  2946. }
  2947. func (_ fastpathT) EncMapStringUintV(v map[string]uint, e *Encoder) {
  2948. if v == nil {
  2949. e.e.EncodeNil()
  2950. return
  2951. }
  2952. ee, esep := e.e, e.hh.hasElemSeparators()
  2953. ee.WriteMapStart(len(v))
  2954. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  2955. if e.h.Canonical {
  2956. v2 := make([]string, len(v))
  2957. var i int
  2958. for k, _ := range v {
  2959. v2[i] = string(k)
  2960. i++
  2961. }
  2962. sort.Sort(stringSlice(v2))
  2963. for _, k2 := range v2 {
  2964. if esep {
  2965. ee.WriteMapElemKey()
  2966. }
  2967. if asSymbols {
  2968. ee.EncodeSymbol(k2)
  2969. } else {
  2970. ee.EncodeString(cUTF8, k2)
  2971. }
  2972. if esep {
  2973. ee.WriteMapElemValue()
  2974. }
  2975. ee.EncodeUint(uint64(v[string(k2)]))
  2976. }
  2977. } else {
  2978. for k2, v2 := range v {
  2979. if esep {
  2980. ee.WriteMapElemKey()
  2981. }
  2982. if asSymbols {
  2983. ee.EncodeSymbol(k2)
  2984. } else {
  2985. ee.EncodeString(cUTF8, k2)
  2986. }
  2987. if esep {
  2988. ee.WriteMapElemValue()
  2989. }
  2990. ee.EncodeUint(uint64(v2))
  2991. }
  2992. }
  2993. ee.WriteMapEnd()
  2994. }
  2995. func (e *Encoder) fastpathEncMapStringUint8R(f *codecFnInfo, rv reflect.Value) {
  2996. fastpathTV.EncMapStringUint8V(rv2i(rv).(map[string]uint8), e)
  2997. }
  2998. func (_ fastpathT) EncMapStringUint8V(v map[string]uint8, e *Encoder) {
  2999. if v == nil {
  3000. e.e.EncodeNil()
  3001. return
  3002. }
  3003. ee, esep := e.e, e.hh.hasElemSeparators()
  3004. ee.WriteMapStart(len(v))
  3005. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  3006. if e.h.Canonical {
  3007. v2 := make([]string, len(v))
  3008. var i int
  3009. for k, _ := range v {
  3010. v2[i] = string(k)
  3011. i++
  3012. }
  3013. sort.Sort(stringSlice(v2))
  3014. for _, k2 := range v2 {
  3015. if esep {
  3016. ee.WriteMapElemKey()
  3017. }
  3018. if asSymbols {
  3019. ee.EncodeSymbol(k2)
  3020. } else {
  3021. ee.EncodeString(cUTF8, k2)
  3022. }
  3023. if esep {
  3024. ee.WriteMapElemValue()
  3025. }
  3026. ee.EncodeUint(uint64(v[string(k2)]))
  3027. }
  3028. } else {
  3029. for k2, v2 := range v {
  3030. if esep {
  3031. ee.WriteMapElemKey()
  3032. }
  3033. if asSymbols {
  3034. ee.EncodeSymbol(k2)
  3035. } else {
  3036. ee.EncodeString(cUTF8, k2)
  3037. }
  3038. if esep {
  3039. ee.WriteMapElemValue()
  3040. }
  3041. ee.EncodeUint(uint64(v2))
  3042. }
  3043. }
  3044. ee.WriteMapEnd()
  3045. }
  3046. func (e *Encoder) fastpathEncMapStringUint16R(f *codecFnInfo, rv reflect.Value) {
  3047. fastpathTV.EncMapStringUint16V(rv2i(rv).(map[string]uint16), e)
  3048. }
  3049. func (_ fastpathT) EncMapStringUint16V(v map[string]uint16, e *Encoder) {
  3050. if v == nil {
  3051. e.e.EncodeNil()
  3052. return
  3053. }
  3054. ee, esep := e.e, e.hh.hasElemSeparators()
  3055. ee.WriteMapStart(len(v))
  3056. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  3057. if e.h.Canonical {
  3058. v2 := make([]string, len(v))
  3059. var i int
  3060. for k, _ := range v {
  3061. v2[i] = string(k)
  3062. i++
  3063. }
  3064. sort.Sort(stringSlice(v2))
  3065. for _, k2 := range v2 {
  3066. if esep {
  3067. ee.WriteMapElemKey()
  3068. }
  3069. if asSymbols {
  3070. ee.EncodeSymbol(k2)
  3071. } else {
  3072. ee.EncodeString(cUTF8, k2)
  3073. }
  3074. if esep {
  3075. ee.WriteMapElemValue()
  3076. }
  3077. ee.EncodeUint(uint64(v[string(k2)]))
  3078. }
  3079. } else {
  3080. for k2, v2 := range v {
  3081. if esep {
  3082. ee.WriteMapElemKey()
  3083. }
  3084. if asSymbols {
  3085. ee.EncodeSymbol(k2)
  3086. } else {
  3087. ee.EncodeString(cUTF8, k2)
  3088. }
  3089. if esep {
  3090. ee.WriteMapElemValue()
  3091. }
  3092. ee.EncodeUint(uint64(v2))
  3093. }
  3094. }
  3095. ee.WriteMapEnd()
  3096. }
  3097. func (e *Encoder) fastpathEncMapStringUint32R(f *codecFnInfo, rv reflect.Value) {
  3098. fastpathTV.EncMapStringUint32V(rv2i(rv).(map[string]uint32), e)
  3099. }
  3100. func (_ fastpathT) EncMapStringUint32V(v map[string]uint32, e *Encoder) {
  3101. if v == nil {
  3102. e.e.EncodeNil()
  3103. return
  3104. }
  3105. ee, esep := e.e, e.hh.hasElemSeparators()
  3106. ee.WriteMapStart(len(v))
  3107. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  3108. if e.h.Canonical {
  3109. v2 := make([]string, len(v))
  3110. var i int
  3111. for k, _ := range v {
  3112. v2[i] = string(k)
  3113. i++
  3114. }
  3115. sort.Sort(stringSlice(v2))
  3116. for _, k2 := range v2 {
  3117. if esep {
  3118. ee.WriteMapElemKey()
  3119. }
  3120. if asSymbols {
  3121. ee.EncodeSymbol(k2)
  3122. } else {
  3123. ee.EncodeString(cUTF8, k2)
  3124. }
  3125. if esep {
  3126. ee.WriteMapElemValue()
  3127. }
  3128. ee.EncodeUint(uint64(v[string(k2)]))
  3129. }
  3130. } else {
  3131. for k2, v2 := range v {
  3132. if esep {
  3133. ee.WriteMapElemKey()
  3134. }
  3135. if asSymbols {
  3136. ee.EncodeSymbol(k2)
  3137. } else {
  3138. ee.EncodeString(cUTF8, k2)
  3139. }
  3140. if esep {
  3141. ee.WriteMapElemValue()
  3142. }
  3143. ee.EncodeUint(uint64(v2))
  3144. }
  3145. }
  3146. ee.WriteMapEnd()
  3147. }
  3148. func (e *Encoder) fastpathEncMapStringUint64R(f *codecFnInfo, rv reflect.Value) {
  3149. fastpathTV.EncMapStringUint64V(rv2i(rv).(map[string]uint64), e)
  3150. }
  3151. func (_ fastpathT) EncMapStringUint64V(v map[string]uint64, e *Encoder) {
  3152. if v == nil {
  3153. e.e.EncodeNil()
  3154. return
  3155. }
  3156. ee, esep := e.e, e.hh.hasElemSeparators()
  3157. ee.WriteMapStart(len(v))
  3158. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  3159. if e.h.Canonical {
  3160. v2 := make([]string, len(v))
  3161. var i int
  3162. for k, _ := range v {
  3163. v2[i] = string(k)
  3164. i++
  3165. }
  3166. sort.Sort(stringSlice(v2))
  3167. for _, k2 := range v2 {
  3168. if esep {
  3169. ee.WriteMapElemKey()
  3170. }
  3171. if asSymbols {
  3172. ee.EncodeSymbol(k2)
  3173. } else {
  3174. ee.EncodeString(cUTF8, k2)
  3175. }
  3176. if esep {
  3177. ee.WriteMapElemValue()
  3178. }
  3179. ee.EncodeUint(uint64(v[string(k2)]))
  3180. }
  3181. } else {
  3182. for k2, v2 := range v {
  3183. if esep {
  3184. ee.WriteMapElemKey()
  3185. }
  3186. if asSymbols {
  3187. ee.EncodeSymbol(k2)
  3188. } else {
  3189. ee.EncodeString(cUTF8, k2)
  3190. }
  3191. if esep {
  3192. ee.WriteMapElemValue()
  3193. }
  3194. ee.EncodeUint(uint64(v2))
  3195. }
  3196. }
  3197. ee.WriteMapEnd()
  3198. }
  3199. func (e *Encoder) fastpathEncMapStringUintptrR(f *codecFnInfo, rv reflect.Value) {
  3200. fastpathTV.EncMapStringUintptrV(rv2i(rv).(map[string]uintptr), e)
  3201. }
  3202. func (_ fastpathT) EncMapStringUintptrV(v map[string]uintptr, e *Encoder) {
  3203. if v == nil {
  3204. e.e.EncodeNil()
  3205. return
  3206. }
  3207. ee, esep := e.e, e.hh.hasElemSeparators()
  3208. ee.WriteMapStart(len(v))
  3209. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  3210. if e.h.Canonical {
  3211. v2 := make([]string, len(v))
  3212. var i int
  3213. for k, _ := range v {
  3214. v2[i] = string(k)
  3215. i++
  3216. }
  3217. sort.Sort(stringSlice(v2))
  3218. for _, k2 := range v2 {
  3219. if esep {
  3220. ee.WriteMapElemKey()
  3221. }
  3222. if asSymbols {
  3223. ee.EncodeSymbol(k2)
  3224. } else {
  3225. ee.EncodeString(cUTF8, k2)
  3226. }
  3227. if esep {
  3228. ee.WriteMapElemValue()
  3229. }
  3230. e.encode(v[string(k2)])
  3231. }
  3232. } else {
  3233. for k2, v2 := range v {
  3234. if esep {
  3235. ee.WriteMapElemKey()
  3236. }
  3237. if asSymbols {
  3238. ee.EncodeSymbol(k2)
  3239. } else {
  3240. ee.EncodeString(cUTF8, k2)
  3241. }
  3242. if esep {
  3243. ee.WriteMapElemValue()
  3244. }
  3245. e.encode(v2)
  3246. }
  3247. }
  3248. ee.WriteMapEnd()
  3249. }
  3250. func (e *Encoder) fastpathEncMapStringIntR(f *codecFnInfo, rv reflect.Value) {
  3251. fastpathTV.EncMapStringIntV(rv2i(rv).(map[string]int), e)
  3252. }
  3253. func (_ fastpathT) EncMapStringIntV(v map[string]int, e *Encoder) {
  3254. if v == nil {
  3255. e.e.EncodeNil()
  3256. return
  3257. }
  3258. ee, esep := e.e, e.hh.hasElemSeparators()
  3259. ee.WriteMapStart(len(v))
  3260. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  3261. if e.h.Canonical {
  3262. v2 := make([]string, len(v))
  3263. var i int
  3264. for k, _ := range v {
  3265. v2[i] = string(k)
  3266. i++
  3267. }
  3268. sort.Sort(stringSlice(v2))
  3269. for _, k2 := range v2 {
  3270. if esep {
  3271. ee.WriteMapElemKey()
  3272. }
  3273. if asSymbols {
  3274. ee.EncodeSymbol(k2)
  3275. } else {
  3276. ee.EncodeString(cUTF8, k2)
  3277. }
  3278. if esep {
  3279. ee.WriteMapElemValue()
  3280. }
  3281. ee.EncodeInt(int64(v[string(k2)]))
  3282. }
  3283. } else {
  3284. for k2, v2 := range v {
  3285. if esep {
  3286. ee.WriteMapElemKey()
  3287. }
  3288. if asSymbols {
  3289. ee.EncodeSymbol(k2)
  3290. } else {
  3291. ee.EncodeString(cUTF8, k2)
  3292. }
  3293. if esep {
  3294. ee.WriteMapElemValue()
  3295. }
  3296. ee.EncodeInt(int64(v2))
  3297. }
  3298. }
  3299. ee.WriteMapEnd()
  3300. }
  3301. func (e *Encoder) fastpathEncMapStringInt8R(f *codecFnInfo, rv reflect.Value) {
  3302. fastpathTV.EncMapStringInt8V(rv2i(rv).(map[string]int8), e)
  3303. }
  3304. func (_ fastpathT) EncMapStringInt8V(v map[string]int8, e *Encoder) {
  3305. if v == nil {
  3306. e.e.EncodeNil()
  3307. return
  3308. }
  3309. ee, esep := e.e, e.hh.hasElemSeparators()
  3310. ee.WriteMapStart(len(v))
  3311. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  3312. if e.h.Canonical {
  3313. v2 := make([]string, len(v))
  3314. var i int
  3315. for k, _ := range v {
  3316. v2[i] = string(k)
  3317. i++
  3318. }
  3319. sort.Sort(stringSlice(v2))
  3320. for _, k2 := range v2 {
  3321. if esep {
  3322. ee.WriteMapElemKey()
  3323. }
  3324. if asSymbols {
  3325. ee.EncodeSymbol(k2)
  3326. } else {
  3327. ee.EncodeString(cUTF8, k2)
  3328. }
  3329. if esep {
  3330. ee.WriteMapElemValue()
  3331. }
  3332. ee.EncodeInt(int64(v[string(k2)]))
  3333. }
  3334. } else {
  3335. for k2, v2 := range v {
  3336. if esep {
  3337. ee.WriteMapElemKey()
  3338. }
  3339. if asSymbols {
  3340. ee.EncodeSymbol(k2)
  3341. } else {
  3342. ee.EncodeString(cUTF8, k2)
  3343. }
  3344. if esep {
  3345. ee.WriteMapElemValue()
  3346. }
  3347. ee.EncodeInt(int64(v2))
  3348. }
  3349. }
  3350. ee.WriteMapEnd()
  3351. }
  3352. func (e *Encoder) fastpathEncMapStringInt16R(f *codecFnInfo, rv reflect.Value) {
  3353. fastpathTV.EncMapStringInt16V(rv2i(rv).(map[string]int16), e)
  3354. }
  3355. func (_ fastpathT) EncMapStringInt16V(v map[string]int16, e *Encoder) {
  3356. if v == nil {
  3357. e.e.EncodeNil()
  3358. return
  3359. }
  3360. ee, esep := e.e, e.hh.hasElemSeparators()
  3361. ee.WriteMapStart(len(v))
  3362. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  3363. if e.h.Canonical {
  3364. v2 := make([]string, len(v))
  3365. var i int
  3366. for k, _ := range v {
  3367. v2[i] = string(k)
  3368. i++
  3369. }
  3370. sort.Sort(stringSlice(v2))
  3371. for _, k2 := range v2 {
  3372. if esep {
  3373. ee.WriteMapElemKey()
  3374. }
  3375. if asSymbols {
  3376. ee.EncodeSymbol(k2)
  3377. } else {
  3378. ee.EncodeString(cUTF8, k2)
  3379. }
  3380. if esep {
  3381. ee.WriteMapElemValue()
  3382. }
  3383. ee.EncodeInt(int64(v[string(k2)]))
  3384. }
  3385. } else {
  3386. for k2, v2 := range v {
  3387. if esep {
  3388. ee.WriteMapElemKey()
  3389. }
  3390. if asSymbols {
  3391. ee.EncodeSymbol(k2)
  3392. } else {
  3393. ee.EncodeString(cUTF8, k2)
  3394. }
  3395. if esep {
  3396. ee.WriteMapElemValue()
  3397. }
  3398. ee.EncodeInt(int64(v2))
  3399. }
  3400. }
  3401. ee.WriteMapEnd()
  3402. }
  3403. func (e *Encoder) fastpathEncMapStringInt32R(f *codecFnInfo, rv reflect.Value) {
  3404. fastpathTV.EncMapStringInt32V(rv2i(rv).(map[string]int32), e)
  3405. }
  3406. func (_ fastpathT) EncMapStringInt32V(v map[string]int32, e *Encoder) {
  3407. if v == nil {
  3408. e.e.EncodeNil()
  3409. return
  3410. }
  3411. ee, esep := e.e, e.hh.hasElemSeparators()
  3412. ee.WriteMapStart(len(v))
  3413. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  3414. if e.h.Canonical {
  3415. v2 := make([]string, len(v))
  3416. var i int
  3417. for k, _ := range v {
  3418. v2[i] = string(k)
  3419. i++
  3420. }
  3421. sort.Sort(stringSlice(v2))
  3422. for _, k2 := range v2 {
  3423. if esep {
  3424. ee.WriteMapElemKey()
  3425. }
  3426. if asSymbols {
  3427. ee.EncodeSymbol(k2)
  3428. } else {
  3429. ee.EncodeString(cUTF8, k2)
  3430. }
  3431. if esep {
  3432. ee.WriteMapElemValue()
  3433. }
  3434. ee.EncodeInt(int64(v[string(k2)]))
  3435. }
  3436. } else {
  3437. for k2, v2 := range v {
  3438. if esep {
  3439. ee.WriteMapElemKey()
  3440. }
  3441. if asSymbols {
  3442. ee.EncodeSymbol(k2)
  3443. } else {
  3444. ee.EncodeString(cUTF8, k2)
  3445. }
  3446. if esep {
  3447. ee.WriteMapElemValue()
  3448. }
  3449. ee.EncodeInt(int64(v2))
  3450. }
  3451. }
  3452. ee.WriteMapEnd()
  3453. }
  3454. func (e *Encoder) fastpathEncMapStringInt64R(f *codecFnInfo, rv reflect.Value) {
  3455. fastpathTV.EncMapStringInt64V(rv2i(rv).(map[string]int64), e)
  3456. }
  3457. func (_ fastpathT) EncMapStringInt64V(v map[string]int64, e *Encoder) {
  3458. if v == nil {
  3459. e.e.EncodeNil()
  3460. return
  3461. }
  3462. ee, esep := e.e, e.hh.hasElemSeparators()
  3463. ee.WriteMapStart(len(v))
  3464. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  3465. if e.h.Canonical {
  3466. v2 := make([]string, len(v))
  3467. var i int
  3468. for k, _ := range v {
  3469. v2[i] = string(k)
  3470. i++
  3471. }
  3472. sort.Sort(stringSlice(v2))
  3473. for _, k2 := range v2 {
  3474. if esep {
  3475. ee.WriteMapElemKey()
  3476. }
  3477. if asSymbols {
  3478. ee.EncodeSymbol(k2)
  3479. } else {
  3480. ee.EncodeString(cUTF8, k2)
  3481. }
  3482. if esep {
  3483. ee.WriteMapElemValue()
  3484. }
  3485. ee.EncodeInt(int64(v[string(k2)]))
  3486. }
  3487. } else {
  3488. for k2, v2 := range v {
  3489. if esep {
  3490. ee.WriteMapElemKey()
  3491. }
  3492. if asSymbols {
  3493. ee.EncodeSymbol(k2)
  3494. } else {
  3495. ee.EncodeString(cUTF8, k2)
  3496. }
  3497. if esep {
  3498. ee.WriteMapElemValue()
  3499. }
  3500. ee.EncodeInt(int64(v2))
  3501. }
  3502. }
  3503. ee.WriteMapEnd()
  3504. }
  3505. func (e *Encoder) fastpathEncMapStringFloat32R(f *codecFnInfo, rv reflect.Value) {
  3506. fastpathTV.EncMapStringFloat32V(rv2i(rv).(map[string]float32), e)
  3507. }
  3508. func (_ fastpathT) EncMapStringFloat32V(v map[string]float32, e *Encoder) {
  3509. if v == nil {
  3510. e.e.EncodeNil()
  3511. return
  3512. }
  3513. ee, esep := e.e, e.hh.hasElemSeparators()
  3514. ee.WriteMapStart(len(v))
  3515. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  3516. if e.h.Canonical {
  3517. v2 := make([]string, len(v))
  3518. var i int
  3519. for k, _ := range v {
  3520. v2[i] = string(k)
  3521. i++
  3522. }
  3523. sort.Sort(stringSlice(v2))
  3524. for _, k2 := range v2 {
  3525. if esep {
  3526. ee.WriteMapElemKey()
  3527. }
  3528. if asSymbols {
  3529. ee.EncodeSymbol(k2)
  3530. } else {
  3531. ee.EncodeString(cUTF8, k2)
  3532. }
  3533. if esep {
  3534. ee.WriteMapElemValue()
  3535. }
  3536. ee.EncodeFloat32(v[string(k2)])
  3537. }
  3538. } else {
  3539. for k2, v2 := range v {
  3540. if esep {
  3541. ee.WriteMapElemKey()
  3542. }
  3543. if asSymbols {
  3544. ee.EncodeSymbol(k2)
  3545. } else {
  3546. ee.EncodeString(cUTF8, k2)
  3547. }
  3548. if esep {
  3549. ee.WriteMapElemValue()
  3550. }
  3551. ee.EncodeFloat32(v2)
  3552. }
  3553. }
  3554. ee.WriteMapEnd()
  3555. }
  3556. func (e *Encoder) fastpathEncMapStringFloat64R(f *codecFnInfo, rv reflect.Value) {
  3557. fastpathTV.EncMapStringFloat64V(rv2i(rv).(map[string]float64), e)
  3558. }
  3559. func (_ fastpathT) EncMapStringFloat64V(v map[string]float64, e *Encoder) {
  3560. if v == nil {
  3561. e.e.EncodeNil()
  3562. return
  3563. }
  3564. ee, esep := e.e, e.hh.hasElemSeparators()
  3565. ee.WriteMapStart(len(v))
  3566. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  3567. if e.h.Canonical {
  3568. v2 := make([]string, len(v))
  3569. var i int
  3570. for k, _ := range v {
  3571. v2[i] = string(k)
  3572. i++
  3573. }
  3574. sort.Sort(stringSlice(v2))
  3575. for _, k2 := range v2 {
  3576. if esep {
  3577. ee.WriteMapElemKey()
  3578. }
  3579. if asSymbols {
  3580. ee.EncodeSymbol(k2)
  3581. } else {
  3582. ee.EncodeString(cUTF8, k2)
  3583. }
  3584. if esep {
  3585. ee.WriteMapElemValue()
  3586. }
  3587. ee.EncodeFloat64(v[string(k2)])
  3588. }
  3589. } else {
  3590. for k2, v2 := range v {
  3591. if esep {
  3592. ee.WriteMapElemKey()
  3593. }
  3594. if asSymbols {
  3595. ee.EncodeSymbol(k2)
  3596. } else {
  3597. ee.EncodeString(cUTF8, k2)
  3598. }
  3599. if esep {
  3600. ee.WriteMapElemValue()
  3601. }
  3602. ee.EncodeFloat64(v2)
  3603. }
  3604. }
  3605. ee.WriteMapEnd()
  3606. }
  3607. func (e *Encoder) fastpathEncMapStringBoolR(f *codecFnInfo, rv reflect.Value) {
  3608. fastpathTV.EncMapStringBoolV(rv2i(rv).(map[string]bool), e)
  3609. }
  3610. func (_ fastpathT) EncMapStringBoolV(v map[string]bool, e *Encoder) {
  3611. if v == nil {
  3612. e.e.EncodeNil()
  3613. return
  3614. }
  3615. ee, esep := e.e, e.hh.hasElemSeparators()
  3616. ee.WriteMapStart(len(v))
  3617. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  3618. if e.h.Canonical {
  3619. v2 := make([]string, len(v))
  3620. var i int
  3621. for k, _ := range v {
  3622. v2[i] = string(k)
  3623. i++
  3624. }
  3625. sort.Sort(stringSlice(v2))
  3626. for _, k2 := range v2 {
  3627. if esep {
  3628. ee.WriteMapElemKey()
  3629. }
  3630. if asSymbols {
  3631. ee.EncodeSymbol(k2)
  3632. } else {
  3633. ee.EncodeString(cUTF8, k2)
  3634. }
  3635. if esep {
  3636. ee.WriteMapElemValue()
  3637. }
  3638. ee.EncodeBool(v[string(k2)])
  3639. }
  3640. } else {
  3641. for k2, v2 := range v {
  3642. if esep {
  3643. ee.WriteMapElemKey()
  3644. }
  3645. if asSymbols {
  3646. ee.EncodeSymbol(k2)
  3647. } else {
  3648. ee.EncodeString(cUTF8, k2)
  3649. }
  3650. if esep {
  3651. ee.WriteMapElemValue()
  3652. }
  3653. ee.EncodeBool(v2)
  3654. }
  3655. }
  3656. ee.WriteMapEnd()
  3657. }
  3658. func (e *Encoder) fastpathEncMapFloat32IntfR(f *codecFnInfo, rv reflect.Value) {
  3659. fastpathTV.EncMapFloat32IntfV(rv2i(rv).(map[float32]interface{}), e)
  3660. }
  3661. func (_ fastpathT) EncMapFloat32IntfV(v map[float32]interface{}, e *Encoder) {
  3662. if v == nil {
  3663. e.e.EncodeNil()
  3664. return
  3665. }
  3666. ee, esep := e.e, e.hh.hasElemSeparators()
  3667. ee.WriteMapStart(len(v))
  3668. if e.h.Canonical {
  3669. v2 := make([]float64, len(v))
  3670. var i int
  3671. for k, _ := range v {
  3672. v2[i] = float64(k)
  3673. i++
  3674. }
  3675. sort.Sort(floatSlice(v2))
  3676. for _, k2 := range v2 {
  3677. if esep {
  3678. ee.WriteMapElemKey()
  3679. }
  3680. ee.EncodeFloat32(float32(k2))
  3681. if esep {
  3682. ee.WriteMapElemValue()
  3683. }
  3684. e.encode(v[float32(k2)])
  3685. }
  3686. } else {
  3687. for k2, v2 := range v {
  3688. if esep {
  3689. ee.WriteMapElemKey()
  3690. }
  3691. ee.EncodeFloat32(k2)
  3692. if esep {
  3693. ee.WriteMapElemValue()
  3694. }
  3695. e.encode(v2)
  3696. }
  3697. }
  3698. ee.WriteMapEnd()
  3699. }
  3700. func (e *Encoder) fastpathEncMapFloat32StringR(f *codecFnInfo, rv reflect.Value) {
  3701. fastpathTV.EncMapFloat32StringV(rv2i(rv).(map[float32]string), e)
  3702. }
  3703. func (_ fastpathT) EncMapFloat32StringV(v map[float32]string, e *Encoder) {
  3704. if v == nil {
  3705. e.e.EncodeNil()
  3706. return
  3707. }
  3708. ee, esep := e.e, e.hh.hasElemSeparators()
  3709. ee.WriteMapStart(len(v))
  3710. if e.h.Canonical {
  3711. v2 := make([]float64, len(v))
  3712. var i int
  3713. for k, _ := range v {
  3714. v2[i] = float64(k)
  3715. i++
  3716. }
  3717. sort.Sort(floatSlice(v2))
  3718. for _, k2 := range v2 {
  3719. if esep {
  3720. ee.WriteMapElemKey()
  3721. }
  3722. ee.EncodeFloat32(float32(k2))
  3723. if esep {
  3724. ee.WriteMapElemValue()
  3725. }
  3726. ee.EncodeString(cUTF8, v[float32(k2)])
  3727. }
  3728. } else {
  3729. for k2, v2 := range v {
  3730. if esep {
  3731. ee.WriteMapElemKey()
  3732. }
  3733. ee.EncodeFloat32(k2)
  3734. if esep {
  3735. ee.WriteMapElemValue()
  3736. }
  3737. ee.EncodeString(cUTF8, v2)
  3738. }
  3739. }
  3740. ee.WriteMapEnd()
  3741. }
  3742. func (e *Encoder) fastpathEncMapFloat32UintR(f *codecFnInfo, rv reflect.Value) {
  3743. fastpathTV.EncMapFloat32UintV(rv2i(rv).(map[float32]uint), e)
  3744. }
  3745. func (_ fastpathT) EncMapFloat32UintV(v map[float32]uint, e *Encoder) {
  3746. if v == nil {
  3747. e.e.EncodeNil()
  3748. return
  3749. }
  3750. ee, esep := e.e, e.hh.hasElemSeparators()
  3751. ee.WriteMapStart(len(v))
  3752. if e.h.Canonical {
  3753. v2 := make([]float64, len(v))
  3754. var i int
  3755. for k, _ := range v {
  3756. v2[i] = float64(k)
  3757. i++
  3758. }
  3759. sort.Sort(floatSlice(v2))
  3760. for _, k2 := range v2 {
  3761. if esep {
  3762. ee.WriteMapElemKey()
  3763. }
  3764. ee.EncodeFloat32(float32(k2))
  3765. if esep {
  3766. ee.WriteMapElemValue()
  3767. }
  3768. ee.EncodeUint(uint64(v[float32(k2)]))
  3769. }
  3770. } else {
  3771. for k2, v2 := range v {
  3772. if esep {
  3773. ee.WriteMapElemKey()
  3774. }
  3775. ee.EncodeFloat32(k2)
  3776. if esep {
  3777. ee.WriteMapElemValue()
  3778. }
  3779. ee.EncodeUint(uint64(v2))
  3780. }
  3781. }
  3782. ee.WriteMapEnd()
  3783. }
  3784. func (e *Encoder) fastpathEncMapFloat32Uint8R(f *codecFnInfo, rv reflect.Value) {
  3785. fastpathTV.EncMapFloat32Uint8V(rv2i(rv).(map[float32]uint8), e)
  3786. }
  3787. func (_ fastpathT) EncMapFloat32Uint8V(v map[float32]uint8, e *Encoder) {
  3788. if v == nil {
  3789. e.e.EncodeNil()
  3790. return
  3791. }
  3792. ee, esep := e.e, e.hh.hasElemSeparators()
  3793. ee.WriteMapStart(len(v))
  3794. if e.h.Canonical {
  3795. v2 := make([]float64, len(v))
  3796. var i int
  3797. for k, _ := range v {
  3798. v2[i] = float64(k)
  3799. i++
  3800. }
  3801. sort.Sort(floatSlice(v2))
  3802. for _, k2 := range v2 {
  3803. if esep {
  3804. ee.WriteMapElemKey()
  3805. }
  3806. ee.EncodeFloat32(float32(k2))
  3807. if esep {
  3808. ee.WriteMapElemValue()
  3809. }
  3810. ee.EncodeUint(uint64(v[float32(k2)]))
  3811. }
  3812. } else {
  3813. for k2, v2 := range v {
  3814. if esep {
  3815. ee.WriteMapElemKey()
  3816. }
  3817. ee.EncodeFloat32(k2)
  3818. if esep {
  3819. ee.WriteMapElemValue()
  3820. }
  3821. ee.EncodeUint(uint64(v2))
  3822. }
  3823. }
  3824. ee.WriteMapEnd()
  3825. }
  3826. func (e *Encoder) fastpathEncMapFloat32Uint16R(f *codecFnInfo, rv reflect.Value) {
  3827. fastpathTV.EncMapFloat32Uint16V(rv2i(rv).(map[float32]uint16), e)
  3828. }
  3829. func (_ fastpathT) EncMapFloat32Uint16V(v map[float32]uint16, e *Encoder) {
  3830. if v == nil {
  3831. e.e.EncodeNil()
  3832. return
  3833. }
  3834. ee, esep := e.e, e.hh.hasElemSeparators()
  3835. ee.WriteMapStart(len(v))
  3836. if e.h.Canonical {
  3837. v2 := make([]float64, len(v))
  3838. var i int
  3839. for k, _ := range v {
  3840. v2[i] = float64(k)
  3841. i++
  3842. }
  3843. sort.Sort(floatSlice(v2))
  3844. for _, k2 := range v2 {
  3845. if esep {
  3846. ee.WriteMapElemKey()
  3847. }
  3848. ee.EncodeFloat32(float32(k2))
  3849. if esep {
  3850. ee.WriteMapElemValue()
  3851. }
  3852. ee.EncodeUint(uint64(v[float32(k2)]))
  3853. }
  3854. } else {
  3855. for k2, v2 := range v {
  3856. if esep {
  3857. ee.WriteMapElemKey()
  3858. }
  3859. ee.EncodeFloat32(k2)
  3860. if esep {
  3861. ee.WriteMapElemValue()
  3862. }
  3863. ee.EncodeUint(uint64(v2))
  3864. }
  3865. }
  3866. ee.WriteMapEnd()
  3867. }
  3868. func (e *Encoder) fastpathEncMapFloat32Uint32R(f *codecFnInfo, rv reflect.Value) {
  3869. fastpathTV.EncMapFloat32Uint32V(rv2i(rv).(map[float32]uint32), e)
  3870. }
  3871. func (_ fastpathT) EncMapFloat32Uint32V(v map[float32]uint32, e *Encoder) {
  3872. if v == nil {
  3873. e.e.EncodeNil()
  3874. return
  3875. }
  3876. ee, esep := e.e, e.hh.hasElemSeparators()
  3877. ee.WriteMapStart(len(v))
  3878. if e.h.Canonical {
  3879. v2 := make([]float64, len(v))
  3880. var i int
  3881. for k, _ := range v {
  3882. v2[i] = float64(k)
  3883. i++
  3884. }
  3885. sort.Sort(floatSlice(v2))
  3886. for _, k2 := range v2 {
  3887. if esep {
  3888. ee.WriteMapElemKey()
  3889. }
  3890. ee.EncodeFloat32(float32(k2))
  3891. if esep {
  3892. ee.WriteMapElemValue()
  3893. }
  3894. ee.EncodeUint(uint64(v[float32(k2)]))
  3895. }
  3896. } else {
  3897. for k2, v2 := range v {
  3898. if esep {
  3899. ee.WriteMapElemKey()
  3900. }
  3901. ee.EncodeFloat32(k2)
  3902. if esep {
  3903. ee.WriteMapElemValue()
  3904. }
  3905. ee.EncodeUint(uint64(v2))
  3906. }
  3907. }
  3908. ee.WriteMapEnd()
  3909. }
  3910. func (e *Encoder) fastpathEncMapFloat32Uint64R(f *codecFnInfo, rv reflect.Value) {
  3911. fastpathTV.EncMapFloat32Uint64V(rv2i(rv).(map[float32]uint64), e)
  3912. }
  3913. func (_ fastpathT) EncMapFloat32Uint64V(v map[float32]uint64, e *Encoder) {
  3914. if v == nil {
  3915. e.e.EncodeNil()
  3916. return
  3917. }
  3918. ee, esep := e.e, e.hh.hasElemSeparators()
  3919. ee.WriteMapStart(len(v))
  3920. if e.h.Canonical {
  3921. v2 := make([]float64, len(v))
  3922. var i int
  3923. for k, _ := range v {
  3924. v2[i] = float64(k)
  3925. i++
  3926. }
  3927. sort.Sort(floatSlice(v2))
  3928. for _, k2 := range v2 {
  3929. if esep {
  3930. ee.WriteMapElemKey()
  3931. }
  3932. ee.EncodeFloat32(float32(k2))
  3933. if esep {
  3934. ee.WriteMapElemValue()
  3935. }
  3936. ee.EncodeUint(uint64(v[float32(k2)]))
  3937. }
  3938. } else {
  3939. for k2, v2 := range v {
  3940. if esep {
  3941. ee.WriteMapElemKey()
  3942. }
  3943. ee.EncodeFloat32(k2)
  3944. if esep {
  3945. ee.WriteMapElemValue()
  3946. }
  3947. ee.EncodeUint(uint64(v2))
  3948. }
  3949. }
  3950. ee.WriteMapEnd()
  3951. }
  3952. func (e *Encoder) fastpathEncMapFloat32UintptrR(f *codecFnInfo, rv reflect.Value) {
  3953. fastpathTV.EncMapFloat32UintptrV(rv2i(rv).(map[float32]uintptr), e)
  3954. }
  3955. func (_ fastpathT) EncMapFloat32UintptrV(v map[float32]uintptr, e *Encoder) {
  3956. if v == nil {
  3957. e.e.EncodeNil()
  3958. return
  3959. }
  3960. ee, esep := e.e, e.hh.hasElemSeparators()
  3961. ee.WriteMapStart(len(v))
  3962. if e.h.Canonical {
  3963. v2 := make([]float64, len(v))
  3964. var i int
  3965. for k, _ := range v {
  3966. v2[i] = float64(k)
  3967. i++
  3968. }
  3969. sort.Sort(floatSlice(v2))
  3970. for _, k2 := range v2 {
  3971. if esep {
  3972. ee.WriteMapElemKey()
  3973. }
  3974. ee.EncodeFloat32(float32(k2))
  3975. if esep {
  3976. ee.WriteMapElemValue()
  3977. }
  3978. e.encode(v[float32(k2)])
  3979. }
  3980. } else {
  3981. for k2, v2 := range v {
  3982. if esep {
  3983. ee.WriteMapElemKey()
  3984. }
  3985. ee.EncodeFloat32(k2)
  3986. if esep {
  3987. ee.WriteMapElemValue()
  3988. }
  3989. e.encode(v2)
  3990. }
  3991. }
  3992. ee.WriteMapEnd()
  3993. }
  3994. func (e *Encoder) fastpathEncMapFloat32IntR(f *codecFnInfo, rv reflect.Value) {
  3995. fastpathTV.EncMapFloat32IntV(rv2i(rv).(map[float32]int), e)
  3996. }
  3997. func (_ fastpathT) EncMapFloat32IntV(v map[float32]int, e *Encoder) {
  3998. if v == nil {
  3999. e.e.EncodeNil()
  4000. return
  4001. }
  4002. ee, esep := e.e, e.hh.hasElemSeparators()
  4003. ee.WriteMapStart(len(v))
  4004. if e.h.Canonical {
  4005. v2 := make([]float64, len(v))
  4006. var i int
  4007. for k, _ := range v {
  4008. v2[i] = float64(k)
  4009. i++
  4010. }
  4011. sort.Sort(floatSlice(v2))
  4012. for _, k2 := range v2 {
  4013. if esep {
  4014. ee.WriteMapElemKey()
  4015. }
  4016. ee.EncodeFloat32(float32(k2))
  4017. if esep {
  4018. ee.WriteMapElemValue()
  4019. }
  4020. ee.EncodeInt(int64(v[float32(k2)]))
  4021. }
  4022. } else {
  4023. for k2, v2 := range v {
  4024. if esep {
  4025. ee.WriteMapElemKey()
  4026. }
  4027. ee.EncodeFloat32(k2)
  4028. if esep {
  4029. ee.WriteMapElemValue()
  4030. }
  4031. ee.EncodeInt(int64(v2))
  4032. }
  4033. }
  4034. ee.WriteMapEnd()
  4035. }
  4036. func (e *Encoder) fastpathEncMapFloat32Int8R(f *codecFnInfo, rv reflect.Value) {
  4037. fastpathTV.EncMapFloat32Int8V(rv2i(rv).(map[float32]int8), e)
  4038. }
  4039. func (_ fastpathT) EncMapFloat32Int8V(v map[float32]int8, e *Encoder) {
  4040. if v == nil {
  4041. e.e.EncodeNil()
  4042. return
  4043. }
  4044. ee, esep := e.e, e.hh.hasElemSeparators()
  4045. ee.WriteMapStart(len(v))
  4046. if e.h.Canonical {
  4047. v2 := make([]float64, len(v))
  4048. var i int
  4049. for k, _ := range v {
  4050. v2[i] = float64(k)
  4051. i++
  4052. }
  4053. sort.Sort(floatSlice(v2))
  4054. for _, k2 := range v2 {
  4055. if esep {
  4056. ee.WriteMapElemKey()
  4057. }
  4058. ee.EncodeFloat32(float32(k2))
  4059. if esep {
  4060. ee.WriteMapElemValue()
  4061. }
  4062. ee.EncodeInt(int64(v[float32(k2)]))
  4063. }
  4064. } else {
  4065. for k2, v2 := range v {
  4066. if esep {
  4067. ee.WriteMapElemKey()
  4068. }
  4069. ee.EncodeFloat32(k2)
  4070. if esep {
  4071. ee.WriteMapElemValue()
  4072. }
  4073. ee.EncodeInt(int64(v2))
  4074. }
  4075. }
  4076. ee.WriteMapEnd()
  4077. }
  4078. func (e *Encoder) fastpathEncMapFloat32Int16R(f *codecFnInfo, rv reflect.Value) {
  4079. fastpathTV.EncMapFloat32Int16V(rv2i(rv).(map[float32]int16), e)
  4080. }
  4081. func (_ fastpathT) EncMapFloat32Int16V(v map[float32]int16, e *Encoder) {
  4082. if v == nil {
  4083. e.e.EncodeNil()
  4084. return
  4085. }
  4086. ee, esep := e.e, e.hh.hasElemSeparators()
  4087. ee.WriteMapStart(len(v))
  4088. if e.h.Canonical {
  4089. v2 := make([]float64, len(v))
  4090. var i int
  4091. for k, _ := range v {
  4092. v2[i] = float64(k)
  4093. i++
  4094. }
  4095. sort.Sort(floatSlice(v2))
  4096. for _, k2 := range v2 {
  4097. if esep {
  4098. ee.WriteMapElemKey()
  4099. }
  4100. ee.EncodeFloat32(float32(k2))
  4101. if esep {
  4102. ee.WriteMapElemValue()
  4103. }
  4104. ee.EncodeInt(int64(v[float32(k2)]))
  4105. }
  4106. } else {
  4107. for k2, v2 := range v {
  4108. if esep {
  4109. ee.WriteMapElemKey()
  4110. }
  4111. ee.EncodeFloat32(k2)
  4112. if esep {
  4113. ee.WriteMapElemValue()
  4114. }
  4115. ee.EncodeInt(int64(v2))
  4116. }
  4117. }
  4118. ee.WriteMapEnd()
  4119. }
  4120. func (e *Encoder) fastpathEncMapFloat32Int32R(f *codecFnInfo, rv reflect.Value) {
  4121. fastpathTV.EncMapFloat32Int32V(rv2i(rv).(map[float32]int32), e)
  4122. }
  4123. func (_ fastpathT) EncMapFloat32Int32V(v map[float32]int32, e *Encoder) {
  4124. if v == nil {
  4125. e.e.EncodeNil()
  4126. return
  4127. }
  4128. ee, esep := e.e, e.hh.hasElemSeparators()
  4129. ee.WriteMapStart(len(v))
  4130. if e.h.Canonical {
  4131. v2 := make([]float64, len(v))
  4132. var i int
  4133. for k, _ := range v {
  4134. v2[i] = float64(k)
  4135. i++
  4136. }
  4137. sort.Sort(floatSlice(v2))
  4138. for _, k2 := range v2 {
  4139. if esep {
  4140. ee.WriteMapElemKey()
  4141. }
  4142. ee.EncodeFloat32(float32(k2))
  4143. if esep {
  4144. ee.WriteMapElemValue()
  4145. }
  4146. ee.EncodeInt(int64(v[float32(k2)]))
  4147. }
  4148. } else {
  4149. for k2, v2 := range v {
  4150. if esep {
  4151. ee.WriteMapElemKey()
  4152. }
  4153. ee.EncodeFloat32(k2)
  4154. if esep {
  4155. ee.WriteMapElemValue()
  4156. }
  4157. ee.EncodeInt(int64(v2))
  4158. }
  4159. }
  4160. ee.WriteMapEnd()
  4161. }
  4162. func (e *Encoder) fastpathEncMapFloat32Int64R(f *codecFnInfo, rv reflect.Value) {
  4163. fastpathTV.EncMapFloat32Int64V(rv2i(rv).(map[float32]int64), e)
  4164. }
  4165. func (_ fastpathT) EncMapFloat32Int64V(v map[float32]int64, e *Encoder) {
  4166. if v == nil {
  4167. e.e.EncodeNil()
  4168. return
  4169. }
  4170. ee, esep := e.e, e.hh.hasElemSeparators()
  4171. ee.WriteMapStart(len(v))
  4172. if e.h.Canonical {
  4173. v2 := make([]float64, len(v))
  4174. var i int
  4175. for k, _ := range v {
  4176. v2[i] = float64(k)
  4177. i++
  4178. }
  4179. sort.Sort(floatSlice(v2))
  4180. for _, k2 := range v2 {
  4181. if esep {
  4182. ee.WriteMapElemKey()
  4183. }
  4184. ee.EncodeFloat32(float32(k2))
  4185. if esep {
  4186. ee.WriteMapElemValue()
  4187. }
  4188. ee.EncodeInt(int64(v[float32(k2)]))
  4189. }
  4190. } else {
  4191. for k2, v2 := range v {
  4192. if esep {
  4193. ee.WriteMapElemKey()
  4194. }
  4195. ee.EncodeFloat32(k2)
  4196. if esep {
  4197. ee.WriteMapElemValue()
  4198. }
  4199. ee.EncodeInt(int64(v2))
  4200. }
  4201. }
  4202. ee.WriteMapEnd()
  4203. }
  4204. func (e *Encoder) fastpathEncMapFloat32Float32R(f *codecFnInfo, rv reflect.Value) {
  4205. fastpathTV.EncMapFloat32Float32V(rv2i(rv).(map[float32]float32), e)
  4206. }
  4207. func (_ fastpathT) EncMapFloat32Float32V(v map[float32]float32, e *Encoder) {
  4208. if v == nil {
  4209. e.e.EncodeNil()
  4210. return
  4211. }
  4212. ee, esep := e.e, e.hh.hasElemSeparators()
  4213. ee.WriteMapStart(len(v))
  4214. if e.h.Canonical {
  4215. v2 := make([]float64, len(v))
  4216. var i int
  4217. for k, _ := range v {
  4218. v2[i] = float64(k)
  4219. i++
  4220. }
  4221. sort.Sort(floatSlice(v2))
  4222. for _, k2 := range v2 {
  4223. if esep {
  4224. ee.WriteMapElemKey()
  4225. }
  4226. ee.EncodeFloat32(float32(k2))
  4227. if esep {
  4228. ee.WriteMapElemValue()
  4229. }
  4230. ee.EncodeFloat32(v[float32(k2)])
  4231. }
  4232. } else {
  4233. for k2, v2 := range v {
  4234. if esep {
  4235. ee.WriteMapElemKey()
  4236. }
  4237. ee.EncodeFloat32(k2)
  4238. if esep {
  4239. ee.WriteMapElemValue()
  4240. }
  4241. ee.EncodeFloat32(v2)
  4242. }
  4243. }
  4244. ee.WriteMapEnd()
  4245. }
  4246. func (e *Encoder) fastpathEncMapFloat32Float64R(f *codecFnInfo, rv reflect.Value) {
  4247. fastpathTV.EncMapFloat32Float64V(rv2i(rv).(map[float32]float64), e)
  4248. }
  4249. func (_ fastpathT) EncMapFloat32Float64V(v map[float32]float64, e *Encoder) {
  4250. if v == nil {
  4251. e.e.EncodeNil()
  4252. return
  4253. }
  4254. ee, esep := e.e, e.hh.hasElemSeparators()
  4255. ee.WriteMapStart(len(v))
  4256. if e.h.Canonical {
  4257. v2 := make([]float64, len(v))
  4258. var i int
  4259. for k, _ := range v {
  4260. v2[i] = float64(k)
  4261. i++
  4262. }
  4263. sort.Sort(floatSlice(v2))
  4264. for _, k2 := range v2 {
  4265. if esep {
  4266. ee.WriteMapElemKey()
  4267. }
  4268. ee.EncodeFloat32(float32(k2))
  4269. if esep {
  4270. ee.WriteMapElemValue()
  4271. }
  4272. ee.EncodeFloat64(v[float32(k2)])
  4273. }
  4274. } else {
  4275. for k2, v2 := range v {
  4276. if esep {
  4277. ee.WriteMapElemKey()
  4278. }
  4279. ee.EncodeFloat32(k2)
  4280. if esep {
  4281. ee.WriteMapElemValue()
  4282. }
  4283. ee.EncodeFloat64(v2)
  4284. }
  4285. }
  4286. ee.WriteMapEnd()
  4287. }
  4288. func (e *Encoder) fastpathEncMapFloat32BoolR(f *codecFnInfo, rv reflect.Value) {
  4289. fastpathTV.EncMapFloat32BoolV(rv2i(rv).(map[float32]bool), e)
  4290. }
  4291. func (_ fastpathT) EncMapFloat32BoolV(v map[float32]bool, e *Encoder) {
  4292. if v == nil {
  4293. e.e.EncodeNil()
  4294. return
  4295. }
  4296. ee, esep := e.e, e.hh.hasElemSeparators()
  4297. ee.WriteMapStart(len(v))
  4298. if e.h.Canonical {
  4299. v2 := make([]float64, len(v))
  4300. var i int
  4301. for k, _ := range v {
  4302. v2[i] = float64(k)
  4303. i++
  4304. }
  4305. sort.Sort(floatSlice(v2))
  4306. for _, k2 := range v2 {
  4307. if esep {
  4308. ee.WriteMapElemKey()
  4309. }
  4310. ee.EncodeFloat32(float32(k2))
  4311. if esep {
  4312. ee.WriteMapElemValue()
  4313. }
  4314. ee.EncodeBool(v[float32(k2)])
  4315. }
  4316. } else {
  4317. for k2, v2 := range v {
  4318. if esep {
  4319. ee.WriteMapElemKey()
  4320. }
  4321. ee.EncodeFloat32(k2)
  4322. if esep {
  4323. ee.WriteMapElemValue()
  4324. }
  4325. ee.EncodeBool(v2)
  4326. }
  4327. }
  4328. ee.WriteMapEnd()
  4329. }
  4330. func (e *Encoder) fastpathEncMapFloat64IntfR(f *codecFnInfo, rv reflect.Value) {
  4331. fastpathTV.EncMapFloat64IntfV(rv2i(rv).(map[float64]interface{}), e)
  4332. }
  4333. func (_ fastpathT) EncMapFloat64IntfV(v map[float64]interface{}, e *Encoder) {
  4334. if v == nil {
  4335. e.e.EncodeNil()
  4336. return
  4337. }
  4338. ee, esep := e.e, e.hh.hasElemSeparators()
  4339. ee.WriteMapStart(len(v))
  4340. if e.h.Canonical {
  4341. v2 := make([]float64, len(v))
  4342. var i int
  4343. for k, _ := range v {
  4344. v2[i] = float64(k)
  4345. i++
  4346. }
  4347. sort.Sort(floatSlice(v2))
  4348. for _, k2 := range v2 {
  4349. if esep {
  4350. ee.WriteMapElemKey()
  4351. }
  4352. ee.EncodeFloat64(float64(k2))
  4353. if esep {
  4354. ee.WriteMapElemValue()
  4355. }
  4356. e.encode(v[float64(k2)])
  4357. }
  4358. } else {
  4359. for k2, v2 := range v {
  4360. if esep {
  4361. ee.WriteMapElemKey()
  4362. }
  4363. ee.EncodeFloat64(k2)
  4364. if esep {
  4365. ee.WriteMapElemValue()
  4366. }
  4367. e.encode(v2)
  4368. }
  4369. }
  4370. ee.WriteMapEnd()
  4371. }
  4372. func (e *Encoder) fastpathEncMapFloat64StringR(f *codecFnInfo, rv reflect.Value) {
  4373. fastpathTV.EncMapFloat64StringV(rv2i(rv).(map[float64]string), e)
  4374. }
  4375. func (_ fastpathT) EncMapFloat64StringV(v map[float64]string, e *Encoder) {
  4376. if v == nil {
  4377. e.e.EncodeNil()
  4378. return
  4379. }
  4380. ee, esep := e.e, e.hh.hasElemSeparators()
  4381. ee.WriteMapStart(len(v))
  4382. if e.h.Canonical {
  4383. v2 := make([]float64, len(v))
  4384. var i int
  4385. for k, _ := range v {
  4386. v2[i] = float64(k)
  4387. i++
  4388. }
  4389. sort.Sort(floatSlice(v2))
  4390. for _, k2 := range v2 {
  4391. if esep {
  4392. ee.WriteMapElemKey()
  4393. }
  4394. ee.EncodeFloat64(float64(k2))
  4395. if esep {
  4396. ee.WriteMapElemValue()
  4397. }
  4398. ee.EncodeString(cUTF8, v[float64(k2)])
  4399. }
  4400. } else {
  4401. for k2, v2 := range v {
  4402. if esep {
  4403. ee.WriteMapElemKey()
  4404. }
  4405. ee.EncodeFloat64(k2)
  4406. if esep {
  4407. ee.WriteMapElemValue()
  4408. }
  4409. ee.EncodeString(cUTF8, v2)
  4410. }
  4411. }
  4412. ee.WriteMapEnd()
  4413. }
  4414. func (e *Encoder) fastpathEncMapFloat64UintR(f *codecFnInfo, rv reflect.Value) {
  4415. fastpathTV.EncMapFloat64UintV(rv2i(rv).(map[float64]uint), e)
  4416. }
  4417. func (_ fastpathT) EncMapFloat64UintV(v map[float64]uint, e *Encoder) {
  4418. if v == nil {
  4419. e.e.EncodeNil()
  4420. return
  4421. }
  4422. ee, esep := e.e, e.hh.hasElemSeparators()
  4423. ee.WriteMapStart(len(v))
  4424. if e.h.Canonical {
  4425. v2 := make([]float64, len(v))
  4426. var i int
  4427. for k, _ := range v {
  4428. v2[i] = float64(k)
  4429. i++
  4430. }
  4431. sort.Sort(floatSlice(v2))
  4432. for _, k2 := range v2 {
  4433. if esep {
  4434. ee.WriteMapElemKey()
  4435. }
  4436. ee.EncodeFloat64(float64(k2))
  4437. if esep {
  4438. ee.WriteMapElemValue()
  4439. }
  4440. ee.EncodeUint(uint64(v[float64(k2)]))
  4441. }
  4442. } else {
  4443. for k2, v2 := range v {
  4444. if esep {
  4445. ee.WriteMapElemKey()
  4446. }
  4447. ee.EncodeFloat64(k2)
  4448. if esep {
  4449. ee.WriteMapElemValue()
  4450. }
  4451. ee.EncodeUint(uint64(v2))
  4452. }
  4453. }
  4454. ee.WriteMapEnd()
  4455. }
  4456. func (e *Encoder) fastpathEncMapFloat64Uint8R(f *codecFnInfo, rv reflect.Value) {
  4457. fastpathTV.EncMapFloat64Uint8V(rv2i(rv).(map[float64]uint8), e)
  4458. }
  4459. func (_ fastpathT) EncMapFloat64Uint8V(v map[float64]uint8, e *Encoder) {
  4460. if v == nil {
  4461. e.e.EncodeNil()
  4462. return
  4463. }
  4464. ee, esep := e.e, e.hh.hasElemSeparators()
  4465. ee.WriteMapStart(len(v))
  4466. if e.h.Canonical {
  4467. v2 := make([]float64, len(v))
  4468. var i int
  4469. for k, _ := range v {
  4470. v2[i] = float64(k)
  4471. i++
  4472. }
  4473. sort.Sort(floatSlice(v2))
  4474. for _, k2 := range v2 {
  4475. if esep {
  4476. ee.WriteMapElemKey()
  4477. }
  4478. ee.EncodeFloat64(float64(k2))
  4479. if esep {
  4480. ee.WriteMapElemValue()
  4481. }
  4482. ee.EncodeUint(uint64(v[float64(k2)]))
  4483. }
  4484. } else {
  4485. for k2, v2 := range v {
  4486. if esep {
  4487. ee.WriteMapElemKey()
  4488. }
  4489. ee.EncodeFloat64(k2)
  4490. if esep {
  4491. ee.WriteMapElemValue()
  4492. }
  4493. ee.EncodeUint(uint64(v2))
  4494. }
  4495. }
  4496. ee.WriteMapEnd()
  4497. }
  4498. func (e *Encoder) fastpathEncMapFloat64Uint16R(f *codecFnInfo, rv reflect.Value) {
  4499. fastpathTV.EncMapFloat64Uint16V(rv2i(rv).(map[float64]uint16), e)
  4500. }
  4501. func (_ fastpathT) EncMapFloat64Uint16V(v map[float64]uint16, e *Encoder) {
  4502. if v == nil {
  4503. e.e.EncodeNil()
  4504. return
  4505. }
  4506. ee, esep := e.e, e.hh.hasElemSeparators()
  4507. ee.WriteMapStart(len(v))
  4508. if e.h.Canonical {
  4509. v2 := make([]float64, len(v))
  4510. var i int
  4511. for k, _ := range v {
  4512. v2[i] = float64(k)
  4513. i++
  4514. }
  4515. sort.Sort(floatSlice(v2))
  4516. for _, k2 := range v2 {
  4517. if esep {
  4518. ee.WriteMapElemKey()
  4519. }
  4520. ee.EncodeFloat64(float64(k2))
  4521. if esep {
  4522. ee.WriteMapElemValue()
  4523. }
  4524. ee.EncodeUint(uint64(v[float64(k2)]))
  4525. }
  4526. } else {
  4527. for k2, v2 := range v {
  4528. if esep {
  4529. ee.WriteMapElemKey()
  4530. }
  4531. ee.EncodeFloat64(k2)
  4532. if esep {
  4533. ee.WriteMapElemValue()
  4534. }
  4535. ee.EncodeUint(uint64(v2))
  4536. }
  4537. }
  4538. ee.WriteMapEnd()
  4539. }
  4540. func (e *Encoder) fastpathEncMapFloat64Uint32R(f *codecFnInfo, rv reflect.Value) {
  4541. fastpathTV.EncMapFloat64Uint32V(rv2i(rv).(map[float64]uint32), e)
  4542. }
  4543. func (_ fastpathT) EncMapFloat64Uint32V(v map[float64]uint32, e *Encoder) {
  4544. if v == nil {
  4545. e.e.EncodeNil()
  4546. return
  4547. }
  4548. ee, esep := e.e, e.hh.hasElemSeparators()
  4549. ee.WriteMapStart(len(v))
  4550. if e.h.Canonical {
  4551. v2 := make([]float64, len(v))
  4552. var i int
  4553. for k, _ := range v {
  4554. v2[i] = float64(k)
  4555. i++
  4556. }
  4557. sort.Sort(floatSlice(v2))
  4558. for _, k2 := range v2 {
  4559. if esep {
  4560. ee.WriteMapElemKey()
  4561. }
  4562. ee.EncodeFloat64(float64(k2))
  4563. if esep {
  4564. ee.WriteMapElemValue()
  4565. }
  4566. ee.EncodeUint(uint64(v[float64(k2)]))
  4567. }
  4568. } else {
  4569. for k2, v2 := range v {
  4570. if esep {
  4571. ee.WriteMapElemKey()
  4572. }
  4573. ee.EncodeFloat64(k2)
  4574. if esep {
  4575. ee.WriteMapElemValue()
  4576. }
  4577. ee.EncodeUint(uint64(v2))
  4578. }
  4579. }
  4580. ee.WriteMapEnd()
  4581. }
  4582. func (e *Encoder) fastpathEncMapFloat64Uint64R(f *codecFnInfo, rv reflect.Value) {
  4583. fastpathTV.EncMapFloat64Uint64V(rv2i(rv).(map[float64]uint64), e)
  4584. }
  4585. func (_ fastpathT) EncMapFloat64Uint64V(v map[float64]uint64, e *Encoder) {
  4586. if v == nil {
  4587. e.e.EncodeNil()
  4588. return
  4589. }
  4590. ee, esep := e.e, e.hh.hasElemSeparators()
  4591. ee.WriteMapStart(len(v))
  4592. if e.h.Canonical {
  4593. v2 := make([]float64, len(v))
  4594. var i int
  4595. for k, _ := range v {
  4596. v2[i] = float64(k)
  4597. i++
  4598. }
  4599. sort.Sort(floatSlice(v2))
  4600. for _, k2 := range v2 {
  4601. if esep {
  4602. ee.WriteMapElemKey()
  4603. }
  4604. ee.EncodeFloat64(float64(k2))
  4605. if esep {
  4606. ee.WriteMapElemValue()
  4607. }
  4608. ee.EncodeUint(uint64(v[float64(k2)]))
  4609. }
  4610. } else {
  4611. for k2, v2 := range v {
  4612. if esep {
  4613. ee.WriteMapElemKey()
  4614. }
  4615. ee.EncodeFloat64(k2)
  4616. if esep {
  4617. ee.WriteMapElemValue()
  4618. }
  4619. ee.EncodeUint(uint64(v2))
  4620. }
  4621. }
  4622. ee.WriteMapEnd()
  4623. }
  4624. func (e *Encoder) fastpathEncMapFloat64UintptrR(f *codecFnInfo, rv reflect.Value) {
  4625. fastpathTV.EncMapFloat64UintptrV(rv2i(rv).(map[float64]uintptr), e)
  4626. }
  4627. func (_ fastpathT) EncMapFloat64UintptrV(v map[float64]uintptr, e *Encoder) {
  4628. if v == nil {
  4629. e.e.EncodeNil()
  4630. return
  4631. }
  4632. ee, esep := e.e, e.hh.hasElemSeparators()
  4633. ee.WriteMapStart(len(v))
  4634. if e.h.Canonical {
  4635. v2 := make([]float64, len(v))
  4636. var i int
  4637. for k, _ := range v {
  4638. v2[i] = float64(k)
  4639. i++
  4640. }
  4641. sort.Sort(floatSlice(v2))
  4642. for _, k2 := range v2 {
  4643. if esep {
  4644. ee.WriteMapElemKey()
  4645. }
  4646. ee.EncodeFloat64(float64(k2))
  4647. if esep {
  4648. ee.WriteMapElemValue()
  4649. }
  4650. e.encode(v[float64(k2)])
  4651. }
  4652. } else {
  4653. for k2, v2 := range v {
  4654. if esep {
  4655. ee.WriteMapElemKey()
  4656. }
  4657. ee.EncodeFloat64(k2)
  4658. if esep {
  4659. ee.WriteMapElemValue()
  4660. }
  4661. e.encode(v2)
  4662. }
  4663. }
  4664. ee.WriteMapEnd()
  4665. }
  4666. func (e *Encoder) fastpathEncMapFloat64IntR(f *codecFnInfo, rv reflect.Value) {
  4667. fastpathTV.EncMapFloat64IntV(rv2i(rv).(map[float64]int), e)
  4668. }
  4669. func (_ fastpathT) EncMapFloat64IntV(v map[float64]int, e *Encoder) {
  4670. if v == nil {
  4671. e.e.EncodeNil()
  4672. return
  4673. }
  4674. ee, esep := e.e, e.hh.hasElemSeparators()
  4675. ee.WriteMapStart(len(v))
  4676. if e.h.Canonical {
  4677. v2 := make([]float64, len(v))
  4678. var i int
  4679. for k, _ := range v {
  4680. v2[i] = float64(k)
  4681. i++
  4682. }
  4683. sort.Sort(floatSlice(v2))
  4684. for _, k2 := range v2 {
  4685. if esep {
  4686. ee.WriteMapElemKey()
  4687. }
  4688. ee.EncodeFloat64(float64(k2))
  4689. if esep {
  4690. ee.WriteMapElemValue()
  4691. }
  4692. ee.EncodeInt(int64(v[float64(k2)]))
  4693. }
  4694. } else {
  4695. for k2, v2 := range v {
  4696. if esep {
  4697. ee.WriteMapElemKey()
  4698. }
  4699. ee.EncodeFloat64(k2)
  4700. if esep {
  4701. ee.WriteMapElemValue()
  4702. }
  4703. ee.EncodeInt(int64(v2))
  4704. }
  4705. }
  4706. ee.WriteMapEnd()
  4707. }
  4708. func (e *Encoder) fastpathEncMapFloat64Int8R(f *codecFnInfo, rv reflect.Value) {
  4709. fastpathTV.EncMapFloat64Int8V(rv2i(rv).(map[float64]int8), e)
  4710. }
  4711. func (_ fastpathT) EncMapFloat64Int8V(v map[float64]int8, e *Encoder) {
  4712. if v == nil {
  4713. e.e.EncodeNil()
  4714. return
  4715. }
  4716. ee, esep := e.e, e.hh.hasElemSeparators()
  4717. ee.WriteMapStart(len(v))
  4718. if e.h.Canonical {
  4719. v2 := make([]float64, len(v))
  4720. var i int
  4721. for k, _ := range v {
  4722. v2[i] = float64(k)
  4723. i++
  4724. }
  4725. sort.Sort(floatSlice(v2))
  4726. for _, k2 := range v2 {
  4727. if esep {
  4728. ee.WriteMapElemKey()
  4729. }
  4730. ee.EncodeFloat64(float64(k2))
  4731. if esep {
  4732. ee.WriteMapElemValue()
  4733. }
  4734. ee.EncodeInt(int64(v[float64(k2)]))
  4735. }
  4736. } else {
  4737. for k2, v2 := range v {
  4738. if esep {
  4739. ee.WriteMapElemKey()
  4740. }
  4741. ee.EncodeFloat64(k2)
  4742. if esep {
  4743. ee.WriteMapElemValue()
  4744. }
  4745. ee.EncodeInt(int64(v2))
  4746. }
  4747. }
  4748. ee.WriteMapEnd()
  4749. }
  4750. func (e *Encoder) fastpathEncMapFloat64Int16R(f *codecFnInfo, rv reflect.Value) {
  4751. fastpathTV.EncMapFloat64Int16V(rv2i(rv).(map[float64]int16), e)
  4752. }
  4753. func (_ fastpathT) EncMapFloat64Int16V(v map[float64]int16, e *Encoder) {
  4754. if v == nil {
  4755. e.e.EncodeNil()
  4756. return
  4757. }
  4758. ee, esep := e.e, e.hh.hasElemSeparators()
  4759. ee.WriteMapStart(len(v))
  4760. if e.h.Canonical {
  4761. v2 := make([]float64, len(v))
  4762. var i int
  4763. for k, _ := range v {
  4764. v2[i] = float64(k)
  4765. i++
  4766. }
  4767. sort.Sort(floatSlice(v2))
  4768. for _, k2 := range v2 {
  4769. if esep {
  4770. ee.WriteMapElemKey()
  4771. }
  4772. ee.EncodeFloat64(float64(k2))
  4773. if esep {
  4774. ee.WriteMapElemValue()
  4775. }
  4776. ee.EncodeInt(int64(v[float64(k2)]))
  4777. }
  4778. } else {
  4779. for k2, v2 := range v {
  4780. if esep {
  4781. ee.WriteMapElemKey()
  4782. }
  4783. ee.EncodeFloat64(k2)
  4784. if esep {
  4785. ee.WriteMapElemValue()
  4786. }
  4787. ee.EncodeInt(int64(v2))
  4788. }
  4789. }
  4790. ee.WriteMapEnd()
  4791. }
  4792. func (e *Encoder) fastpathEncMapFloat64Int32R(f *codecFnInfo, rv reflect.Value) {
  4793. fastpathTV.EncMapFloat64Int32V(rv2i(rv).(map[float64]int32), e)
  4794. }
  4795. func (_ fastpathT) EncMapFloat64Int32V(v map[float64]int32, e *Encoder) {
  4796. if v == nil {
  4797. e.e.EncodeNil()
  4798. return
  4799. }
  4800. ee, esep := e.e, e.hh.hasElemSeparators()
  4801. ee.WriteMapStart(len(v))
  4802. if e.h.Canonical {
  4803. v2 := make([]float64, len(v))
  4804. var i int
  4805. for k, _ := range v {
  4806. v2[i] = float64(k)
  4807. i++
  4808. }
  4809. sort.Sort(floatSlice(v2))
  4810. for _, k2 := range v2 {
  4811. if esep {
  4812. ee.WriteMapElemKey()
  4813. }
  4814. ee.EncodeFloat64(float64(k2))
  4815. if esep {
  4816. ee.WriteMapElemValue()
  4817. }
  4818. ee.EncodeInt(int64(v[float64(k2)]))
  4819. }
  4820. } else {
  4821. for k2, v2 := range v {
  4822. if esep {
  4823. ee.WriteMapElemKey()
  4824. }
  4825. ee.EncodeFloat64(k2)
  4826. if esep {
  4827. ee.WriteMapElemValue()
  4828. }
  4829. ee.EncodeInt(int64(v2))
  4830. }
  4831. }
  4832. ee.WriteMapEnd()
  4833. }
  4834. func (e *Encoder) fastpathEncMapFloat64Int64R(f *codecFnInfo, rv reflect.Value) {
  4835. fastpathTV.EncMapFloat64Int64V(rv2i(rv).(map[float64]int64), e)
  4836. }
  4837. func (_ fastpathT) EncMapFloat64Int64V(v map[float64]int64, e *Encoder) {
  4838. if v == nil {
  4839. e.e.EncodeNil()
  4840. return
  4841. }
  4842. ee, esep := e.e, e.hh.hasElemSeparators()
  4843. ee.WriteMapStart(len(v))
  4844. if e.h.Canonical {
  4845. v2 := make([]float64, len(v))
  4846. var i int
  4847. for k, _ := range v {
  4848. v2[i] = float64(k)
  4849. i++
  4850. }
  4851. sort.Sort(floatSlice(v2))
  4852. for _, k2 := range v2 {
  4853. if esep {
  4854. ee.WriteMapElemKey()
  4855. }
  4856. ee.EncodeFloat64(float64(k2))
  4857. if esep {
  4858. ee.WriteMapElemValue()
  4859. }
  4860. ee.EncodeInt(int64(v[float64(k2)]))
  4861. }
  4862. } else {
  4863. for k2, v2 := range v {
  4864. if esep {
  4865. ee.WriteMapElemKey()
  4866. }
  4867. ee.EncodeFloat64(k2)
  4868. if esep {
  4869. ee.WriteMapElemValue()
  4870. }
  4871. ee.EncodeInt(int64(v2))
  4872. }
  4873. }
  4874. ee.WriteMapEnd()
  4875. }
  4876. func (e *Encoder) fastpathEncMapFloat64Float32R(f *codecFnInfo, rv reflect.Value) {
  4877. fastpathTV.EncMapFloat64Float32V(rv2i(rv).(map[float64]float32), e)
  4878. }
  4879. func (_ fastpathT) EncMapFloat64Float32V(v map[float64]float32, e *Encoder) {
  4880. if v == nil {
  4881. e.e.EncodeNil()
  4882. return
  4883. }
  4884. ee, esep := e.e, e.hh.hasElemSeparators()
  4885. ee.WriteMapStart(len(v))
  4886. if e.h.Canonical {
  4887. v2 := make([]float64, len(v))
  4888. var i int
  4889. for k, _ := range v {
  4890. v2[i] = float64(k)
  4891. i++
  4892. }
  4893. sort.Sort(floatSlice(v2))
  4894. for _, k2 := range v2 {
  4895. if esep {
  4896. ee.WriteMapElemKey()
  4897. }
  4898. ee.EncodeFloat64(float64(k2))
  4899. if esep {
  4900. ee.WriteMapElemValue()
  4901. }
  4902. ee.EncodeFloat32(v[float64(k2)])
  4903. }
  4904. } else {
  4905. for k2, v2 := range v {
  4906. if esep {
  4907. ee.WriteMapElemKey()
  4908. }
  4909. ee.EncodeFloat64(k2)
  4910. if esep {
  4911. ee.WriteMapElemValue()
  4912. }
  4913. ee.EncodeFloat32(v2)
  4914. }
  4915. }
  4916. ee.WriteMapEnd()
  4917. }
  4918. func (e *Encoder) fastpathEncMapFloat64Float64R(f *codecFnInfo, rv reflect.Value) {
  4919. fastpathTV.EncMapFloat64Float64V(rv2i(rv).(map[float64]float64), e)
  4920. }
  4921. func (_ fastpathT) EncMapFloat64Float64V(v map[float64]float64, e *Encoder) {
  4922. if v == nil {
  4923. e.e.EncodeNil()
  4924. return
  4925. }
  4926. ee, esep := e.e, e.hh.hasElemSeparators()
  4927. ee.WriteMapStart(len(v))
  4928. if e.h.Canonical {
  4929. v2 := make([]float64, len(v))
  4930. var i int
  4931. for k, _ := range v {
  4932. v2[i] = float64(k)
  4933. i++
  4934. }
  4935. sort.Sort(floatSlice(v2))
  4936. for _, k2 := range v2 {
  4937. if esep {
  4938. ee.WriteMapElemKey()
  4939. }
  4940. ee.EncodeFloat64(float64(k2))
  4941. if esep {
  4942. ee.WriteMapElemValue()
  4943. }
  4944. ee.EncodeFloat64(v[float64(k2)])
  4945. }
  4946. } else {
  4947. for k2, v2 := range v {
  4948. if esep {
  4949. ee.WriteMapElemKey()
  4950. }
  4951. ee.EncodeFloat64(k2)
  4952. if esep {
  4953. ee.WriteMapElemValue()
  4954. }
  4955. ee.EncodeFloat64(v2)
  4956. }
  4957. }
  4958. ee.WriteMapEnd()
  4959. }
  4960. func (e *Encoder) fastpathEncMapFloat64BoolR(f *codecFnInfo, rv reflect.Value) {
  4961. fastpathTV.EncMapFloat64BoolV(rv2i(rv).(map[float64]bool), e)
  4962. }
  4963. func (_ fastpathT) EncMapFloat64BoolV(v map[float64]bool, e *Encoder) {
  4964. if v == nil {
  4965. e.e.EncodeNil()
  4966. return
  4967. }
  4968. ee, esep := e.e, e.hh.hasElemSeparators()
  4969. ee.WriteMapStart(len(v))
  4970. if e.h.Canonical {
  4971. v2 := make([]float64, len(v))
  4972. var i int
  4973. for k, _ := range v {
  4974. v2[i] = float64(k)
  4975. i++
  4976. }
  4977. sort.Sort(floatSlice(v2))
  4978. for _, k2 := range v2 {
  4979. if esep {
  4980. ee.WriteMapElemKey()
  4981. }
  4982. ee.EncodeFloat64(float64(k2))
  4983. if esep {
  4984. ee.WriteMapElemValue()
  4985. }
  4986. ee.EncodeBool(v[float64(k2)])
  4987. }
  4988. } else {
  4989. for k2, v2 := range v {
  4990. if esep {
  4991. ee.WriteMapElemKey()
  4992. }
  4993. ee.EncodeFloat64(k2)
  4994. if esep {
  4995. ee.WriteMapElemValue()
  4996. }
  4997. ee.EncodeBool(v2)
  4998. }
  4999. }
  5000. ee.WriteMapEnd()
  5001. }
  5002. func (e *Encoder) fastpathEncMapUintIntfR(f *codecFnInfo, rv reflect.Value) {
  5003. fastpathTV.EncMapUintIntfV(rv2i(rv).(map[uint]interface{}), e)
  5004. }
  5005. func (_ fastpathT) EncMapUintIntfV(v map[uint]interface{}, e *Encoder) {
  5006. if v == nil {
  5007. e.e.EncodeNil()
  5008. return
  5009. }
  5010. ee, esep := e.e, e.hh.hasElemSeparators()
  5011. ee.WriteMapStart(len(v))
  5012. if e.h.Canonical {
  5013. v2 := make([]uint64, len(v))
  5014. var i int
  5015. for k, _ := range v {
  5016. v2[i] = uint64(k)
  5017. i++
  5018. }
  5019. sort.Sort(uintSlice(v2))
  5020. for _, k2 := range v2 {
  5021. if esep {
  5022. ee.WriteMapElemKey()
  5023. }
  5024. ee.EncodeUint(uint64(uint(k2)))
  5025. if esep {
  5026. ee.WriteMapElemValue()
  5027. }
  5028. e.encode(v[uint(k2)])
  5029. }
  5030. } else {
  5031. for k2, v2 := range v {
  5032. if esep {
  5033. ee.WriteMapElemKey()
  5034. }
  5035. ee.EncodeUint(uint64(k2))
  5036. if esep {
  5037. ee.WriteMapElemValue()
  5038. }
  5039. e.encode(v2)
  5040. }
  5041. }
  5042. ee.WriteMapEnd()
  5043. }
  5044. func (e *Encoder) fastpathEncMapUintStringR(f *codecFnInfo, rv reflect.Value) {
  5045. fastpathTV.EncMapUintStringV(rv2i(rv).(map[uint]string), e)
  5046. }
  5047. func (_ fastpathT) EncMapUintStringV(v map[uint]string, e *Encoder) {
  5048. if v == nil {
  5049. e.e.EncodeNil()
  5050. return
  5051. }
  5052. ee, esep := e.e, e.hh.hasElemSeparators()
  5053. ee.WriteMapStart(len(v))
  5054. if e.h.Canonical {
  5055. v2 := make([]uint64, len(v))
  5056. var i int
  5057. for k, _ := range v {
  5058. v2[i] = uint64(k)
  5059. i++
  5060. }
  5061. sort.Sort(uintSlice(v2))
  5062. for _, k2 := range v2 {
  5063. if esep {
  5064. ee.WriteMapElemKey()
  5065. }
  5066. ee.EncodeUint(uint64(uint(k2)))
  5067. if esep {
  5068. ee.WriteMapElemValue()
  5069. }
  5070. ee.EncodeString(cUTF8, v[uint(k2)])
  5071. }
  5072. } else {
  5073. for k2, v2 := range v {
  5074. if esep {
  5075. ee.WriteMapElemKey()
  5076. }
  5077. ee.EncodeUint(uint64(k2))
  5078. if esep {
  5079. ee.WriteMapElemValue()
  5080. }
  5081. ee.EncodeString(cUTF8, v2)
  5082. }
  5083. }
  5084. ee.WriteMapEnd()
  5085. }
  5086. func (e *Encoder) fastpathEncMapUintUintR(f *codecFnInfo, rv reflect.Value) {
  5087. fastpathTV.EncMapUintUintV(rv2i(rv).(map[uint]uint), e)
  5088. }
  5089. func (_ fastpathT) EncMapUintUintV(v map[uint]uint, e *Encoder) {
  5090. if v == nil {
  5091. e.e.EncodeNil()
  5092. return
  5093. }
  5094. ee, esep := e.e, e.hh.hasElemSeparators()
  5095. ee.WriteMapStart(len(v))
  5096. if e.h.Canonical {
  5097. v2 := make([]uint64, len(v))
  5098. var i int
  5099. for k, _ := range v {
  5100. v2[i] = uint64(k)
  5101. i++
  5102. }
  5103. sort.Sort(uintSlice(v2))
  5104. for _, k2 := range v2 {
  5105. if esep {
  5106. ee.WriteMapElemKey()
  5107. }
  5108. ee.EncodeUint(uint64(uint(k2)))
  5109. if esep {
  5110. ee.WriteMapElemValue()
  5111. }
  5112. ee.EncodeUint(uint64(v[uint(k2)]))
  5113. }
  5114. } else {
  5115. for k2, v2 := range v {
  5116. if esep {
  5117. ee.WriteMapElemKey()
  5118. }
  5119. ee.EncodeUint(uint64(k2))
  5120. if esep {
  5121. ee.WriteMapElemValue()
  5122. }
  5123. ee.EncodeUint(uint64(v2))
  5124. }
  5125. }
  5126. ee.WriteMapEnd()
  5127. }
  5128. func (e *Encoder) fastpathEncMapUintUint8R(f *codecFnInfo, rv reflect.Value) {
  5129. fastpathTV.EncMapUintUint8V(rv2i(rv).(map[uint]uint8), e)
  5130. }
  5131. func (_ fastpathT) EncMapUintUint8V(v map[uint]uint8, e *Encoder) {
  5132. if v == nil {
  5133. e.e.EncodeNil()
  5134. return
  5135. }
  5136. ee, esep := e.e, e.hh.hasElemSeparators()
  5137. ee.WriteMapStart(len(v))
  5138. if e.h.Canonical {
  5139. v2 := make([]uint64, len(v))
  5140. var i int
  5141. for k, _ := range v {
  5142. v2[i] = uint64(k)
  5143. i++
  5144. }
  5145. sort.Sort(uintSlice(v2))
  5146. for _, k2 := range v2 {
  5147. if esep {
  5148. ee.WriteMapElemKey()
  5149. }
  5150. ee.EncodeUint(uint64(uint(k2)))
  5151. if esep {
  5152. ee.WriteMapElemValue()
  5153. }
  5154. ee.EncodeUint(uint64(v[uint(k2)]))
  5155. }
  5156. } else {
  5157. for k2, v2 := range v {
  5158. if esep {
  5159. ee.WriteMapElemKey()
  5160. }
  5161. ee.EncodeUint(uint64(k2))
  5162. if esep {
  5163. ee.WriteMapElemValue()
  5164. }
  5165. ee.EncodeUint(uint64(v2))
  5166. }
  5167. }
  5168. ee.WriteMapEnd()
  5169. }
  5170. func (e *Encoder) fastpathEncMapUintUint16R(f *codecFnInfo, rv reflect.Value) {
  5171. fastpathTV.EncMapUintUint16V(rv2i(rv).(map[uint]uint16), e)
  5172. }
  5173. func (_ fastpathT) EncMapUintUint16V(v map[uint]uint16, e *Encoder) {
  5174. if v == nil {
  5175. e.e.EncodeNil()
  5176. return
  5177. }
  5178. ee, esep := e.e, e.hh.hasElemSeparators()
  5179. ee.WriteMapStart(len(v))
  5180. if e.h.Canonical {
  5181. v2 := make([]uint64, len(v))
  5182. var i int
  5183. for k, _ := range v {
  5184. v2[i] = uint64(k)
  5185. i++
  5186. }
  5187. sort.Sort(uintSlice(v2))
  5188. for _, k2 := range v2 {
  5189. if esep {
  5190. ee.WriteMapElemKey()
  5191. }
  5192. ee.EncodeUint(uint64(uint(k2)))
  5193. if esep {
  5194. ee.WriteMapElemValue()
  5195. }
  5196. ee.EncodeUint(uint64(v[uint(k2)]))
  5197. }
  5198. } else {
  5199. for k2, v2 := range v {
  5200. if esep {
  5201. ee.WriteMapElemKey()
  5202. }
  5203. ee.EncodeUint(uint64(k2))
  5204. if esep {
  5205. ee.WriteMapElemValue()
  5206. }
  5207. ee.EncodeUint(uint64(v2))
  5208. }
  5209. }
  5210. ee.WriteMapEnd()
  5211. }
  5212. func (e *Encoder) fastpathEncMapUintUint32R(f *codecFnInfo, rv reflect.Value) {
  5213. fastpathTV.EncMapUintUint32V(rv2i(rv).(map[uint]uint32), e)
  5214. }
  5215. func (_ fastpathT) EncMapUintUint32V(v map[uint]uint32, e *Encoder) {
  5216. if v == nil {
  5217. e.e.EncodeNil()
  5218. return
  5219. }
  5220. ee, esep := e.e, e.hh.hasElemSeparators()
  5221. ee.WriteMapStart(len(v))
  5222. if e.h.Canonical {
  5223. v2 := make([]uint64, len(v))
  5224. var i int
  5225. for k, _ := range v {
  5226. v2[i] = uint64(k)
  5227. i++
  5228. }
  5229. sort.Sort(uintSlice(v2))
  5230. for _, k2 := range v2 {
  5231. if esep {
  5232. ee.WriteMapElemKey()
  5233. }
  5234. ee.EncodeUint(uint64(uint(k2)))
  5235. if esep {
  5236. ee.WriteMapElemValue()
  5237. }
  5238. ee.EncodeUint(uint64(v[uint(k2)]))
  5239. }
  5240. } else {
  5241. for k2, v2 := range v {
  5242. if esep {
  5243. ee.WriteMapElemKey()
  5244. }
  5245. ee.EncodeUint(uint64(k2))
  5246. if esep {
  5247. ee.WriteMapElemValue()
  5248. }
  5249. ee.EncodeUint(uint64(v2))
  5250. }
  5251. }
  5252. ee.WriteMapEnd()
  5253. }
  5254. func (e *Encoder) fastpathEncMapUintUint64R(f *codecFnInfo, rv reflect.Value) {
  5255. fastpathTV.EncMapUintUint64V(rv2i(rv).(map[uint]uint64), e)
  5256. }
  5257. func (_ fastpathT) EncMapUintUint64V(v map[uint]uint64, e *Encoder) {
  5258. if v == nil {
  5259. e.e.EncodeNil()
  5260. return
  5261. }
  5262. ee, esep := e.e, e.hh.hasElemSeparators()
  5263. ee.WriteMapStart(len(v))
  5264. if e.h.Canonical {
  5265. v2 := make([]uint64, len(v))
  5266. var i int
  5267. for k, _ := range v {
  5268. v2[i] = uint64(k)
  5269. i++
  5270. }
  5271. sort.Sort(uintSlice(v2))
  5272. for _, k2 := range v2 {
  5273. if esep {
  5274. ee.WriteMapElemKey()
  5275. }
  5276. ee.EncodeUint(uint64(uint(k2)))
  5277. if esep {
  5278. ee.WriteMapElemValue()
  5279. }
  5280. ee.EncodeUint(uint64(v[uint(k2)]))
  5281. }
  5282. } else {
  5283. for k2, v2 := range v {
  5284. if esep {
  5285. ee.WriteMapElemKey()
  5286. }
  5287. ee.EncodeUint(uint64(k2))
  5288. if esep {
  5289. ee.WriteMapElemValue()
  5290. }
  5291. ee.EncodeUint(uint64(v2))
  5292. }
  5293. }
  5294. ee.WriteMapEnd()
  5295. }
  5296. func (e *Encoder) fastpathEncMapUintUintptrR(f *codecFnInfo, rv reflect.Value) {
  5297. fastpathTV.EncMapUintUintptrV(rv2i(rv).(map[uint]uintptr), e)
  5298. }
  5299. func (_ fastpathT) EncMapUintUintptrV(v map[uint]uintptr, e *Encoder) {
  5300. if v == nil {
  5301. e.e.EncodeNil()
  5302. return
  5303. }
  5304. ee, esep := e.e, e.hh.hasElemSeparators()
  5305. ee.WriteMapStart(len(v))
  5306. if e.h.Canonical {
  5307. v2 := make([]uint64, len(v))
  5308. var i int
  5309. for k, _ := range v {
  5310. v2[i] = uint64(k)
  5311. i++
  5312. }
  5313. sort.Sort(uintSlice(v2))
  5314. for _, k2 := range v2 {
  5315. if esep {
  5316. ee.WriteMapElemKey()
  5317. }
  5318. ee.EncodeUint(uint64(uint(k2)))
  5319. if esep {
  5320. ee.WriteMapElemValue()
  5321. }
  5322. e.encode(v[uint(k2)])
  5323. }
  5324. } else {
  5325. for k2, v2 := range v {
  5326. if esep {
  5327. ee.WriteMapElemKey()
  5328. }
  5329. ee.EncodeUint(uint64(k2))
  5330. if esep {
  5331. ee.WriteMapElemValue()
  5332. }
  5333. e.encode(v2)
  5334. }
  5335. }
  5336. ee.WriteMapEnd()
  5337. }
  5338. func (e *Encoder) fastpathEncMapUintIntR(f *codecFnInfo, rv reflect.Value) {
  5339. fastpathTV.EncMapUintIntV(rv2i(rv).(map[uint]int), e)
  5340. }
  5341. func (_ fastpathT) EncMapUintIntV(v map[uint]int, e *Encoder) {
  5342. if v == nil {
  5343. e.e.EncodeNil()
  5344. return
  5345. }
  5346. ee, esep := e.e, e.hh.hasElemSeparators()
  5347. ee.WriteMapStart(len(v))
  5348. if e.h.Canonical {
  5349. v2 := make([]uint64, len(v))
  5350. var i int
  5351. for k, _ := range v {
  5352. v2[i] = uint64(k)
  5353. i++
  5354. }
  5355. sort.Sort(uintSlice(v2))
  5356. for _, k2 := range v2 {
  5357. if esep {
  5358. ee.WriteMapElemKey()
  5359. }
  5360. ee.EncodeUint(uint64(uint(k2)))
  5361. if esep {
  5362. ee.WriteMapElemValue()
  5363. }
  5364. ee.EncodeInt(int64(v[uint(k2)]))
  5365. }
  5366. } else {
  5367. for k2, v2 := range v {
  5368. if esep {
  5369. ee.WriteMapElemKey()
  5370. }
  5371. ee.EncodeUint(uint64(k2))
  5372. if esep {
  5373. ee.WriteMapElemValue()
  5374. }
  5375. ee.EncodeInt(int64(v2))
  5376. }
  5377. }
  5378. ee.WriteMapEnd()
  5379. }
  5380. func (e *Encoder) fastpathEncMapUintInt8R(f *codecFnInfo, rv reflect.Value) {
  5381. fastpathTV.EncMapUintInt8V(rv2i(rv).(map[uint]int8), e)
  5382. }
  5383. func (_ fastpathT) EncMapUintInt8V(v map[uint]int8, e *Encoder) {
  5384. if v == nil {
  5385. e.e.EncodeNil()
  5386. return
  5387. }
  5388. ee, esep := e.e, e.hh.hasElemSeparators()
  5389. ee.WriteMapStart(len(v))
  5390. if e.h.Canonical {
  5391. v2 := make([]uint64, len(v))
  5392. var i int
  5393. for k, _ := range v {
  5394. v2[i] = uint64(k)
  5395. i++
  5396. }
  5397. sort.Sort(uintSlice(v2))
  5398. for _, k2 := range v2 {
  5399. if esep {
  5400. ee.WriteMapElemKey()
  5401. }
  5402. ee.EncodeUint(uint64(uint(k2)))
  5403. if esep {
  5404. ee.WriteMapElemValue()
  5405. }
  5406. ee.EncodeInt(int64(v[uint(k2)]))
  5407. }
  5408. } else {
  5409. for k2, v2 := range v {
  5410. if esep {
  5411. ee.WriteMapElemKey()
  5412. }
  5413. ee.EncodeUint(uint64(k2))
  5414. if esep {
  5415. ee.WriteMapElemValue()
  5416. }
  5417. ee.EncodeInt(int64(v2))
  5418. }
  5419. }
  5420. ee.WriteMapEnd()
  5421. }
  5422. func (e *Encoder) fastpathEncMapUintInt16R(f *codecFnInfo, rv reflect.Value) {
  5423. fastpathTV.EncMapUintInt16V(rv2i(rv).(map[uint]int16), e)
  5424. }
  5425. func (_ fastpathT) EncMapUintInt16V(v map[uint]int16, e *Encoder) {
  5426. if v == nil {
  5427. e.e.EncodeNil()
  5428. return
  5429. }
  5430. ee, esep := e.e, e.hh.hasElemSeparators()
  5431. ee.WriteMapStart(len(v))
  5432. if e.h.Canonical {
  5433. v2 := make([]uint64, len(v))
  5434. var i int
  5435. for k, _ := range v {
  5436. v2[i] = uint64(k)
  5437. i++
  5438. }
  5439. sort.Sort(uintSlice(v2))
  5440. for _, k2 := range v2 {
  5441. if esep {
  5442. ee.WriteMapElemKey()
  5443. }
  5444. ee.EncodeUint(uint64(uint(k2)))
  5445. if esep {
  5446. ee.WriteMapElemValue()
  5447. }
  5448. ee.EncodeInt(int64(v[uint(k2)]))
  5449. }
  5450. } else {
  5451. for k2, v2 := range v {
  5452. if esep {
  5453. ee.WriteMapElemKey()
  5454. }
  5455. ee.EncodeUint(uint64(k2))
  5456. if esep {
  5457. ee.WriteMapElemValue()
  5458. }
  5459. ee.EncodeInt(int64(v2))
  5460. }
  5461. }
  5462. ee.WriteMapEnd()
  5463. }
  5464. func (e *Encoder) fastpathEncMapUintInt32R(f *codecFnInfo, rv reflect.Value) {
  5465. fastpathTV.EncMapUintInt32V(rv2i(rv).(map[uint]int32), e)
  5466. }
  5467. func (_ fastpathT) EncMapUintInt32V(v map[uint]int32, e *Encoder) {
  5468. if v == nil {
  5469. e.e.EncodeNil()
  5470. return
  5471. }
  5472. ee, esep := e.e, e.hh.hasElemSeparators()
  5473. ee.WriteMapStart(len(v))
  5474. if e.h.Canonical {
  5475. v2 := make([]uint64, len(v))
  5476. var i int
  5477. for k, _ := range v {
  5478. v2[i] = uint64(k)
  5479. i++
  5480. }
  5481. sort.Sort(uintSlice(v2))
  5482. for _, k2 := range v2 {
  5483. if esep {
  5484. ee.WriteMapElemKey()
  5485. }
  5486. ee.EncodeUint(uint64(uint(k2)))
  5487. if esep {
  5488. ee.WriteMapElemValue()
  5489. }
  5490. ee.EncodeInt(int64(v[uint(k2)]))
  5491. }
  5492. } else {
  5493. for k2, v2 := range v {
  5494. if esep {
  5495. ee.WriteMapElemKey()
  5496. }
  5497. ee.EncodeUint(uint64(k2))
  5498. if esep {
  5499. ee.WriteMapElemValue()
  5500. }
  5501. ee.EncodeInt(int64(v2))
  5502. }
  5503. }
  5504. ee.WriteMapEnd()
  5505. }
  5506. func (e *Encoder) fastpathEncMapUintInt64R(f *codecFnInfo, rv reflect.Value) {
  5507. fastpathTV.EncMapUintInt64V(rv2i(rv).(map[uint]int64), e)
  5508. }
  5509. func (_ fastpathT) EncMapUintInt64V(v map[uint]int64, e *Encoder) {
  5510. if v == nil {
  5511. e.e.EncodeNil()
  5512. return
  5513. }
  5514. ee, esep := e.e, e.hh.hasElemSeparators()
  5515. ee.WriteMapStart(len(v))
  5516. if e.h.Canonical {
  5517. v2 := make([]uint64, len(v))
  5518. var i int
  5519. for k, _ := range v {
  5520. v2[i] = uint64(k)
  5521. i++
  5522. }
  5523. sort.Sort(uintSlice(v2))
  5524. for _, k2 := range v2 {
  5525. if esep {
  5526. ee.WriteMapElemKey()
  5527. }
  5528. ee.EncodeUint(uint64(uint(k2)))
  5529. if esep {
  5530. ee.WriteMapElemValue()
  5531. }
  5532. ee.EncodeInt(int64(v[uint(k2)]))
  5533. }
  5534. } else {
  5535. for k2, v2 := range v {
  5536. if esep {
  5537. ee.WriteMapElemKey()
  5538. }
  5539. ee.EncodeUint(uint64(k2))
  5540. if esep {
  5541. ee.WriteMapElemValue()
  5542. }
  5543. ee.EncodeInt(int64(v2))
  5544. }
  5545. }
  5546. ee.WriteMapEnd()
  5547. }
  5548. func (e *Encoder) fastpathEncMapUintFloat32R(f *codecFnInfo, rv reflect.Value) {
  5549. fastpathTV.EncMapUintFloat32V(rv2i(rv).(map[uint]float32), e)
  5550. }
  5551. func (_ fastpathT) EncMapUintFloat32V(v map[uint]float32, e *Encoder) {
  5552. if v == nil {
  5553. e.e.EncodeNil()
  5554. return
  5555. }
  5556. ee, esep := e.e, e.hh.hasElemSeparators()
  5557. ee.WriteMapStart(len(v))
  5558. if e.h.Canonical {
  5559. v2 := make([]uint64, len(v))
  5560. var i int
  5561. for k, _ := range v {
  5562. v2[i] = uint64(k)
  5563. i++
  5564. }
  5565. sort.Sort(uintSlice(v2))
  5566. for _, k2 := range v2 {
  5567. if esep {
  5568. ee.WriteMapElemKey()
  5569. }
  5570. ee.EncodeUint(uint64(uint(k2)))
  5571. if esep {
  5572. ee.WriteMapElemValue()
  5573. }
  5574. ee.EncodeFloat32(v[uint(k2)])
  5575. }
  5576. } else {
  5577. for k2, v2 := range v {
  5578. if esep {
  5579. ee.WriteMapElemKey()
  5580. }
  5581. ee.EncodeUint(uint64(k2))
  5582. if esep {
  5583. ee.WriteMapElemValue()
  5584. }
  5585. ee.EncodeFloat32(v2)
  5586. }
  5587. }
  5588. ee.WriteMapEnd()
  5589. }
  5590. func (e *Encoder) fastpathEncMapUintFloat64R(f *codecFnInfo, rv reflect.Value) {
  5591. fastpathTV.EncMapUintFloat64V(rv2i(rv).(map[uint]float64), e)
  5592. }
  5593. func (_ fastpathT) EncMapUintFloat64V(v map[uint]float64, e *Encoder) {
  5594. if v == nil {
  5595. e.e.EncodeNil()
  5596. return
  5597. }
  5598. ee, esep := e.e, e.hh.hasElemSeparators()
  5599. ee.WriteMapStart(len(v))
  5600. if e.h.Canonical {
  5601. v2 := make([]uint64, len(v))
  5602. var i int
  5603. for k, _ := range v {
  5604. v2[i] = uint64(k)
  5605. i++
  5606. }
  5607. sort.Sort(uintSlice(v2))
  5608. for _, k2 := range v2 {
  5609. if esep {
  5610. ee.WriteMapElemKey()
  5611. }
  5612. ee.EncodeUint(uint64(uint(k2)))
  5613. if esep {
  5614. ee.WriteMapElemValue()
  5615. }
  5616. ee.EncodeFloat64(v[uint(k2)])
  5617. }
  5618. } else {
  5619. for k2, v2 := range v {
  5620. if esep {
  5621. ee.WriteMapElemKey()
  5622. }
  5623. ee.EncodeUint(uint64(k2))
  5624. if esep {
  5625. ee.WriteMapElemValue()
  5626. }
  5627. ee.EncodeFloat64(v2)
  5628. }
  5629. }
  5630. ee.WriteMapEnd()
  5631. }
  5632. func (e *Encoder) fastpathEncMapUintBoolR(f *codecFnInfo, rv reflect.Value) {
  5633. fastpathTV.EncMapUintBoolV(rv2i(rv).(map[uint]bool), e)
  5634. }
  5635. func (_ fastpathT) EncMapUintBoolV(v map[uint]bool, e *Encoder) {
  5636. if v == nil {
  5637. e.e.EncodeNil()
  5638. return
  5639. }
  5640. ee, esep := e.e, e.hh.hasElemSeparators()
  5641. ee.WriteMapStart(len(v))
  5642. if e.h.Canonical {
  5643. v2 := make([]uint64, len(v))
  5644. var i int
  5645. for k, _ := range v {
  5646. v2[i] = uint64(k)
  5647. i++
  5648. }
  5649. sort.Sort(uintSlice(v2))
  5650. for _, k2 := range v2 {
  5651. if esep {
  5652. ee.WriteMapElemKey()
  5653. }
  5654. ee.EncodeUint(uint64(uint(k2)))
  5655. if esep {
  5656. ee.WriteMapElemValue()
  5657. }
  5658. ee.EncodeBool(v[uint(k2)])
  5659. }
  5660. } else {
  5661. for k2, v2 := range v {
  5662. if esep {
  5663. ee.WriteMapElemKey()
  5664. }
  5665. ee.EncodeUint(uint64(k2))
  5666. if esep {
  5667. ee.WriteMapElemValue()
  5668. }
  5669. ee.EncodeBool(v2)
  5670. }
  5671. }
  5672. ee.WriteMapEnd()
  5673. }
  5674. func (e *Encoder) fastpathEncMapUint8IntfR(f *codecFnInfo, rv reflect.Value) {
  5675. fastpathTV.EncMapUint8IntfV(rv2i(rv).(map[uint8]interface{}), e)
  5676. }
  5677. func (_ fastpathT) EncMapUint8IntfV(v map[uint8]interface{}, e *Encoder) {
  5678. if v == nil {
  5679. e.e.EncodeNil()
  5680. return
  5681. }
  5682. ee, esep := e.e, e.hh.hasElemSeparators()
  5683. ee.WriteMapStart(len(v))
  5684. if e.h.Canonical {
  5685. v2 := make([]uint64, len(v))
  5686. var i int
  5687. for k, _ := range v {
  5688. v2[i] = uint64(k)
  5689. i++
  5690. }
  5691. sort.Sort(uintSlice(v2))
  5692. for _, k2 := range v2 {
  5693. if esep {
  5694. ee.WriteMapElemKey()
  5695. }
  5696. ee.EncodeUint(uint64(uint8(k2)))
  5697. if esep {
  5698. ee.WriteMapElemValue()
  5699. }
  5700. e.encode(v[uint8(k2)])
  5701. }
  5702. } else {
  5703. for k2, v2 := range v {
  5704. if esep {
  5705. ee.WriteMapElemKey()
  5706. }
  5707. ee.EncodeUint(uint64(k2))
  5708. if esep {
  5709. ee.WriteMapElemValue()
  5710. }
  5711. e.encode(v2)
  5712. }
  5713. }
  5714. ee.WriteMapEnd()
  5715. }
  5716. func (e *Encoder) fastpathEncMapUint8StringR(f *codecFnInfo, rv reflect.Value) {
  5717. fastpathTV.EncMapUint8StringV(rv2i(rv).(map[uint8]string), e)
  5718. }
  5719. func (_ fastpathT) EncMapUint8StringV(v map[uint8]string, e *Encoder) {
  5720. if v == nil {
  5721. e.e.EncodeNil()
  5722. return
  5723. }
  5724. ee, esep := e.e, e.hh.hasElemSeparators()
  5725. ee.WriteMapStart(len(v))
  5726. if e.h.Canonical {
  5727. v2 := make([]uint64, len(v))
  5728. var i int
  5729. for k, _ := range v {
  5730. v2[i] = uint64(k)
  5731. i++
  5732. }
  5733. sort.Sort(uintSlice(v2))
  5734. for _, k2 := range v2 {
  5735. if esep {
  5736. ee.WriteMapElemKey()
  5737. }
  5738. ee.EncodeUint(uint64(uint8(k2)))
  5739. if esep {
  5740. ee.WriteMapElemValue()
  5741. }
  5742. ee.EncodeString(cUTF8, v[uint8(k2)])
  5743. }
  5744. } else {
  5745. for k2, v2 := range v {
  5746. if esep {
  5747. ee.WriteMapElemKey()
  5748. }
  5749. ee.EncodeUint(uint64(k2))
  5750. if esep {
  5751. ee.WriteMapElemValue()
  5752. }
  5753. ee.EncodeString(cUTF8, v2)
  5754. }
  5755. }
  5756. ee.WriteMapEnd()
  5757. }
  5758. func (e *Encoder) fastpathEncMapUint8UintR(f *codecFnInfo, rv reflect.Value) {
  5759. fastpathTV.EncMapUint8UintV(rv2i(rv).(map[uint8]uint), e)
  5760. }
  5761. func (_ fastpathT) EncMapUint8UintV(v map[uint8]uint, e *Encoder) {
  5762. if v == nil {
  5763. e.e.EncodeNil()
  5764. return
  5765. }
  5766. ee, esep := e.e, e.hh.hasElemSeparators()
  5767. ee.WriteMapStart(len(v))
  5768. if e.h.Canonical {
  5769. v2 := make([]uint64, len(v))
  5770. var i int
  5771. for k, _ := range v {
  5772. v2[i] = uint64(k)
  5773. i++
  5774. }
  5775. sort.Sort(uintSlice(v2))
  5776. for _, k2 := range v2 {
  5777. if esep {
  5778. ee.WriteMapElemKey()
  5779. }
  5780. ee.EncodeUint(uint64(uint8(k2)))
  5781. if esep {
  5782. ee.WriteMapElemValue()
  5783. }
  5784. ee.EncodeUint(uint64(v[uint8(k2)]))
  5785. }
  5786. } else {
  5787. for k2, v2 := range v {
  5788. if esep {
  5789. ee.WriteMapElemKey()
  5790. }
  5791. ee.EncodeUint(uint64(k2))
  5792. if esep {
  5793. ee.WriteMapElemValue()
  5794. }
  5795. ee.EncodeUint(uint64(v2))
  5796. }
  5797. }
  5798. ee.WriteMapEnd()
  5799. }
  5800. func (e *Encoder) fastpathEncMapUint8Uint8R(f *codecFnInfo, rv reflect.Value) {
  5801. fastpathTV.EncMapUint8Uint8V(rv2i(rv).(map[uint8]uint8), e)
  5802. }
  5803. func (_ fastpathT) EncMapUint8Uint8V(v map[uint8]uint8, e *Encoder) {
  5804. if v == nil {
  5805. e.e.EncodeNil()
  5806. return
  5807. }
  5808. ee, esep := e.e, e.hh.hasElemSeparators()
  5809. ee.WriteMapStart(len(v))
  5810. if e.h.Canonical {
  5811. v2 := make([]uint64, len(v))
  5812. var i int
  5813. for k, _ := range v {
  5814. v2[i] = uint64(k)
  5815. i++
  5816. }
  5817. sort.Sort(uintSlice(v2))
  5818. for _, k2 := range v2 {
  5819. if esep {
  5820. ee.WriteMapElemKey()
  5821. }
  5822. ee.EncodeUint(uint64(uint8(k2)))
  5823. if esep {
  5824. ee.WriteMapElemValue()
  5825. }
  5826. ee.EncodeUint(uint64(v[uint8(k2)]))
  5827. }
  5828. } else {
  5829. for k2, v2 := range v {
  5830. if esep {
  5831. ee.WriteMapElemKey()
  5832. }
  5833. ee.EncodeUint(uint64(k2))
  5834. if esep {
  5835. ee.WriteMapElemValue()
  5836. }
  5837. ee.EncodeUint(uint64(v2))
  5838. }
  5839. }
  5840. ee.WriteMapEnd()
  5841. }
  5842. func (e *Encoder) fastpathEncMapUint8Uint16R(f *codecFnInfo, rv reflect.Value) {
  5843. fastpathTV.EncMapUint8Uint16V(rv2i(rv).(map[uint8]uint16), e)
  5844. }
  5845. func (_ fastpathT) EncMapUint8Uint16V(v map[uint8]uint16, e *Encoder) {
  5846. if v == nil {
  5847. e.e.EncodeNil()
  5848. return
  5849. }
  5850. ee, esep := e.e, e.hh.hasElemSeparators()
  5851. ee.WriteMapStart(len(v))
  5852. if e.h.Canonical {
  5853. v2 := make([]uint64, len(v))
  5854. var i int
  5855. for k, _ := range v {
  5856. v2[i] = uint64(k)
  5857. i++
  5858. }
  5859. sort.Sort(uintSlice(v2))
  5860. for _, k2 := range v2 {
  5861. if esep {
  5862. ee.WriteMapElemKey()
  5863. }
  5864. ee.EncodeUint(uint64(uint8(k2)))
  5865. if esep {
  5866. ee.WriteMapElemValue()
  5867. }
  5868. ee.EncodeUint(uint64(v[uint8(k2)]))
  5869. }
  5870. } else {
  5871. for k2, v2 := range v {
  5872. if esep {
  5873. ee.WriteMapElemKey()
  5874. }
  5875. ee.EncodeUint(uint64(k2))
  5876. if esep {
  5877. ee.WriteMapElemValue()
  5878. }
  5879. ee.EncodeUint(uint64(v2))
  5880. }
  5881. }
  5882. ee.WriteMapEnd()
  5883. }
  5884. func (e *Encoder) fastpathEncMapUint8Uint32R(f *codecFnInfo, rv reflect.Value) {
  5885. fastpathTV.EncMapUint8Uint32V(rv2i(rv).(map[uint8]uint32), e)
  5886. }
  5887. func (_ fastpathT) EncMapUint8Uint32V(v map[uint8]uint32, e *Encoder) {
  5888. if v == nil {
  5889. e.e.EncodeNil()
  5890. return
  5891. }
  5892. ee, esep := e.e, e.hh.hasElemSeparators()
  5893. ee.WriteMapStart(len(v))
  5894. if e.h.Canonical {
  5895. v2 := make([]uint64, len(v))
  5896. var i int
  5897. for k, _ := range v {
  5898. v2[i] = uint64(k)
  5899. i++
  5900. }
  5901. sort.Sort(uintSlice(v2))
  5902. for _, k2 := range v2 {
  5903. if esep {
  5904. ee.WriteMapElemKey()
  5905. }
  5906. ee.EncodeUint(uint64(uint8(k2)))
  5907. if esep {
  5908. ee.WriteMapElemValue()
  5909. }
  5910. ee.EncodeUint(uint64(v[uint8(k2)]))
  5911. }
  5912. } else {
  5913. for k2, v2 := range v {
  5914. if esep {
  5915. ee.WriteMapElemKey()
  5916. }
  5917. ee.EncodeUint(uint64(k2))
  5918. if esep {
  5919. ee.WriteMapElemValue()
  5920. }
  5921. ee.EncodeUint(uint64(v2))
  5922. }
  5923. }
  5924. ee.WriteMapEnd()
  5925. }
  5926. func (e *Encoder) fastpathEncMapUint8Uint64R(f *codecFnInfo, rv reflect.Value) {
  5927. fastpathTV.EncMapUint8Uint64V(rv2i(rv).(map[uint8]uint64), e)
  5928. }
  5929. func (_ fastpathT) EncMapUint8Uint64V(v map[uint8]uint64, e *Encoder) {
  5930. if v == nil {
  5931. e.e.EncodeNil()
  5932. return
  5933. }
  5934. ee, esep := e.e, e.hh.hasElemSeparators()
  5935. ee.WriteMapStart(len(v))
  5936. if e.h.Canonical {
  5937. v2 := make([]uint64, len(v))
  5938. var i int
  5939. for k, _ := range v {
  5940. v2[i] = uint64(k)
  5941. i++
  5942. }
  5943. sort.Sort(uintSlice(v2))
  5944. for _, k2 := range v2 {
  5945. if esep {
  5946. ee.WriteMapElemKey()
  5947. }
  5948. ee.EncodeUint(uint64(uint8(k2)))
  5949. if esep {
  5950. ee.WriteMapElemValue()
  5951. }
  5952. ee.EncodeUint(uint64(v[uint8(k2)]))
  5953. }
  5954. } else {
  5955. for k2, v2 := range v {
  5956. if esep {
  5957. ee.WriteMapElemKey()
  5958. }
  5959. ee.EncodeUint(uint64(k2))
  5960. if esep {
  5961. ee.WriteMapElemValue()
  5962. }
  5963. ee.EncodeUint(uint64(v2))
  5964. }
  5965. }
  5966. ee.WriteMapEnd()
  5967. }
  5968. func (e *Encoder) fastpathEncMapUint8UintptrR(f *codecFnInfo, rv reflect.Value) {
  5969. fastpathTV.EncMapUint8UintptrV(rv2i(rv).(map[uint8]uintptr), e)
  5970. }
  5971. func (_ fastpathT) EncMapUint8UintptrV(v map[uint8]uintptr, e *Encoder) {
  5972. if v == nil {
  5973. e.e.EncodeNil()
  5974. return
  5975. }
  5976. ee, esep := e.e, e.hh.hasElemSeparators()
  5977. ee.WriteMapStart(len(v))
  5978. if e.h.Canonical {
  5979. v2 := make([]uint64, len(v))
  5980. var i int
  5981. for k, _ := range v {
  5982. v2[i] = uint64(k)
  5983. i++
  5984. }
  5985. sort.Sort(uintSlice(v2))
  5986. for _, k2 := range v2 {
  5987. if esep {
  5988. ee.WriteMapElemKey()
  5989. }
  5990. ee.EncodeUint(uint64(uint8(k2)))
  5991. if esep {
  5992. ee.WriteMapElemValue()
  5993. }
  5994. e.encode(v[uint8(k2)])
  5995. }
  5996. } else {
  5997. for k2, v2 := range v {
  5998. if esep {
  5999. ee.WriteMapElemKey()
  6000. }
  6001. ee.EncodeUint(uint64(k2))
  6002. if esep {
  6003. ee.WriteMapElemValue()
  6004. }
  6005. e.encode(v2)
  6006. }
  6007. }
  6008. ee.WriteMapEnd()
  6009. }
  6010. func (e *Encoder) fastpathEncMapUint8IntR(f *codecFnInfo, rv reflect.Value) {
  6011. fastpathTV.EncMapUint8IntV(rv2i(rv).(map[uint8]int), e)
  6012. }
  6013. func (_ fastpathT) EncMapUint8IntV(v map[uint8]int, e *Encoder) {
  6014. if v == nil {
  6015. e.e.EncodeNil()
  6016. return
  6017. }
  6018. ee, esep := e.e, e.hh.hasElemSeparators()
  6019. ee.WriteMapStart(len(v))
  6020. if e.h.Canonical {
  6021. v2 := make([]uint64, len(v))
  6022. var i int
  6023. for k, _ := range v {
  6024. v2[i] = uint64(k)
  6025. i++
  6026. }
  6027. sort.Sort(uintSlice(v2))
  6028. for _, k2 := range v2 {
  6029. if esep {
  6030. ee.WriteMapElemKey()
  6031. }
  6032. ee.EncodeUint(uint64(uint8(k2)))
  6033. if esep {
  6034. ee.WriteMapElemValue()
  6035. }
  6036. ee.EncodeInt(int64(v[uint8(k2)]))
  6037. }
  6038. } else {
  6039. for k2, v2 := range v {
  6040. if esep {
  6041. ee.WriteMapElemKey()
  6042. }
  6043. ee.EncodeUint(uint64(k2))
  6044. if esep {
  6045. ee.WriteMapElemValue()
  6046. }
  6047. ee.EncodeInt(int64(v2))
  6048. }
  6049. }
  6050. ee.WriteMapEnd()
  6051. }
  6052. func (e *Encoder) fastpathEncMapUint8Int8R(f *codecFnInfo, rv reflect.Value) {
  6053. fastpathTV.EncMapUint8Int8V(rv2i(rv).(map[uint8]int8), e)
  6054. }
  6055. func (_ fastpathT) EncMapUint8Int8V(v map[uint8]int8, e *Encoder) {
  6056. if v == nil {
  6057. e.e.EncodeNil()
  6058. return
  6059. }
  6060. ee, esep := e.e, e.hh.hasElemSeparators()
  6061. ee.WriteMapStart(len(v))
  6062. if e.h.Canonical {
  6063. v2 := make([]uint64, len(v))
  6064. var i int
  6065. for k, _ := range v {
  6066. v2[i] = uint64(k)
  6067. i++
  6068. }
  6069. sort.Sort(uintSlice(v2))
  6070. for _, k2 := range v2 {
  6071. if esep {
  6072. ee.WriteMapElemKey()
  6073. }
  6074. ee.EncodeUint(uint64(uint8(k2)))
  6075. if esep {
  6076. ee.WriteMapElemValue()
  6077. }
  6078. ee.EncodeInt(int64(v[uint8(k2)]))
  6079. }
  6080. } else {
  6081. for k2, v2 := range v {
  6082. if esep {
  6083. ee.WriteMapElemKey()
  6084. }
  6085. ee.EncodeUint(uint64(k2))
  6086. if esep {
  6087. ee.WriteMapElemValue()
  6088. }
  6089. ee.EncodeInt(int64(v2))
  6090. }
  6091. }
  6092. ee.WriteMapEnd()
  6093. }
  6094. func (e *Encoder) fastpathEncMapUint8Int16R(f *codecFnInfo, rv reflect.Value) {
  6095. fastpathTV.EncMapUint8Int16V(rv2i(rv).(map[uint8]int16), e)
  6096. }
  6097. func (_ fastpathT) EncMapUint8Int16V(v map[uint8]int16, e *Encoder) {
  6098. if v == nil {
  6099. e.e.EncodeNil()
  6100. return
  6101. }
  6102. ee, esep := e.e, e.hh.hasElemSeparators()
  6103. ee.WriteMapStart(len(v))
  6104. if e.h.Canonical {
  6105. v2 := make([]uint64, len(v))
  6106. var i int
  6107. for k, _ := range v {
  6108. v2[i] = uint64(k)
  6109. i++
  6110. }
  6111. sort.Sort(uintSlice(v2))
  6112. for _, k2 := range v2 {
  6113. if esep {
  6114. ee.WriteMapElemKey()
  6115. }
  6116. ee.EncodeUint(uint64(uint8(k2)))
  6117. if esep {
  6118. ee.WriteMapElemValue()
  6119. }
  6120. ee.EncodeInt(int64(v[uint8(k2)]))
  6121. }
  6122. } else {
  6123. for k2, v2 := range v {
  6124. if esep {
  6125. ee.WriteMapElemKey()
  6126. }
  6127. ee.EncodeUint(uint64(k2))
  6128. if esep {
  6129. ee.WriteMapElemValue()
  6130. }
  6131. ee.EncodeInt(int64(v2))
  6132. }
  6133. }
  6134. ee.WriteMapEnd()
  6135. }
  6136. func (e *Encoder) fastpathEncMapUint8Int32R(f *codecFnInfo, rv reflect.Value) {
  6137. fastpathTV.EncMapUint8Int32V(rv2i(rv).(map[uint8]int32), e)
  6138. }
  6139. func (_ fastpathT) EncMapUint8Int32V(v map[uint8]int32, e *Encoder) {
  6140. if v == nil {
  6141. e.e.EncodeNil()
  6142. return
  6143. }
  6144. ee, esep := e.e, e.hh.hasElemSeparators()
  6145. ee.WriteMapStart(len(v))
  6146. if e.h.Canonical {
  6147. v2 := make([]uint64, len(v))
  6148. var i int
  6149. for k, _ := range v {
  6150. v2[i] = uint64(k)
  6151. i++
  6152. }
  6153. sort.Sort(uintSlice(v2))
  6154. for _, k2 := range v2 {
  6155. if esep {
  6156. ee.WriteMapElemKey()
  6157. }
  6158. ee.EncodeUint(uint64(uint8(k2)))
  6159. if esep {
  6160. ee.WriteMapElemValue()
  6161. }
  6162. ee.EncodeInt(int64(v[uint8(k2)]))
  6163. }
  6164. } else {
  6165. for k2, v2 := range v {
  6166. if esep {
  6167. ee.WriteMapElemKey()
  6168. }
  6169. ee.EncodeUint(uint64(k2))
  6170. if esep {
  6171. ee.WriteMapElemValue()
  6172. }
  6173. ee.EncodeInt(int64(v2))
  6174. }
  6175. }
  6176. ee.WriteMapEnd()
  6177. }
  6178. func (e *Encoder) fastpathEncMapUint8Int64R(f *codecFnInfo, rv reflect.Value) {
  6179. fastpathTV.EncMapUint8Int64V(rv2i(rv).(map[uint8]int64), e)
  6180. }
  6181. func (_ fastpathT) EncMapUint8Int64V(v map[uint8]int64, e *Encoder) {
  6182. if v == nil {
  6183. e.e.EncodeNil()
  6184. return
  6185. }
  6186. ee, esep := e.e, e.hh.hasElemSeparators()
  6187. ee.WriteMapStart(len(v))
  6188. if e.h.Canonical {
  6189. v2 := make([]uint64, len(v))
  6190. var i int
  6191. for k, _ := range v {
  6192. v2[i] = uint64(k)
  6193. i++
  6194. }
  6195. sort.Sort(uintSlice(v2))
  6196. for _, k2 := range v2 {
  6197. if esep {
  6198. ee.WriteMapElemKey()
  6199. }
  6200. ee.EncodeUint(uint64(uint8(k2)))
  6201. if esep {
  6202. ee.WriteMapElemValue()
  6203. }
  6204. ee.EncodeInt(int64(v[uint8(k2)]))
  6205. }
  6206. } else {
  6207. for k2, v2 := range v {
  6208. if esep {
  6209. ee.WriteMapElemKey()
  6210. }
  6211. ee.EncodeUint(uint64(k2))
  6212. if esep {
  6213. ee.WriteMapElemValue()
  6214. }
  6215. ee.EncodeInt(int64(v2))
  6216. }
  6217. }
  6218. ee.WriteMapEnd()
  6219. }
  6220. func (e *Encoder) fastpathEncMapUint8Float32R(f *codecFnInfo, rv reflect.Value) {
  6221. fastpathTV.EncMapUint8Float32V(rv2i(rv).(map[uint8]float32), e)
  6222. }
  6223. func (_ fastpathT) EncMapUint8Float32V(v map[uint8]float32, e *Encoder) {
  6224. if v == nil {
  6225. e.e.EncodeNil()
  6226. return
  6227. }
  6228. ee, esep := e.e, e.hh.hasElemSeparators()
  6229. ee.WriteMapStart(len(v))
  6230. if e.h.Canonical {
  6231. v2 := make([]uint64, len(v))
  6232. var i int
  6233. for k, _ := range v {
  6234. v2[i] = uint64(k)
  6235. i++
  6236. }
  6237. sort.Sort(uintSlice(v2))
  6238. for _, k2 := range v2 {
  6239. if esep {
  6240. ee.WriteMapElemKey()
  6241. }
  6242. ee.EncodeUint(uint64(uint8(k2)))
  6243. if esep {
  6244. ee.WriteMapElemValue()
  6245. }
  6246. ee.EncodeFloat32(v[uint8(k2)])
  6247. }
  6248. } else {
  6249. for k2, v2 := range v {
  6250. if esep {
  6251. ee.WriteMapElemKey()
  6252. }
  6253. ee.EncodeUint(uint64(k2))
  6254. if esep {
  6255. ee.WriteMapElemValue()
  6256. }
  6257. ee.EncodeFloat32(v2)
  6258. }
  6259. }
  6260. ee.WriteMapEnd()
  6261. }
  6262. func (e *Encoder) fastpathEncMapUint8Float64R(f *codecFnInfo, rv reflect.Value) {
  6263. fastpathTV.EncMapUint8Float64V(rv2i(rv).(map[uint8]float64), e)
  6264. }
  6265. func (_ fastpathT) EncMapUint8Float64V(v map[uint8]float64, e *Encoder) {
  6266. if v == nil {
  6267. e.e.EncodeNil()
  6268. return
  6269. }
  6270. ee, esep := e.e, e.hh.hasElemSeparators()
  6271. ee.WriteMapStart(len(v))
  6272. if e.h.Canonical {
  6273. v2 := make([]uint64, len(v))
  6274. var i int
  6275. for k, _ := range v {
  6276. v2[i] = uint64(k)
  6277. i++
  6278. }
  6279. sort.Sort(uintSlice(v2))
  6280. for _, k2 := range v2 {
  6281. if esep {
  6282. ee.WriteMapElemKey()
  6283. }
  6284. ee.EncodeUint(uint64(uint8(k2)))
  6285. if esep {
  6286. ee.WriteMapElemValue()
  6287. }
  6288. ee.EncodeFloat64(v[uint8(k2)])
  6289. }
  6290. } else {
  6291. for k2, v2 := range v {
  6292. if esep {
  6293. ee.WriteMapElemKey()
  6294. }
  6295. ee.EncodeUint(uint64(k2))
  6296. if esep {
  6297. ee.WriteMapElemValue()
  6298. }
  6299. ee.EncodeFloat64(v2)
  6300. }
  6301. }
  6302. ee.WriteMapEnd()
  6303. }
  6304. func (e *Encoder) fastpathEncMapUint8BoolR(f *codecFnInfo, rv reflect.Value) {
  6305. fastpathTV.EncMapUint8BoolV(rv2i(rv).(map[uint8]bool), e)
  6306. }
  6307. func (_ fastpathT) EncMapUint8BoolV(v map[uint8]bool, e *Encoder) {
  6308. if v == nil {
  6309. e.e.EncodeNil()
  6310. return
  6311. }
  6312. ee, esep := e.e, e.hh.hasElemSeparators()
  6313. ee.WriteMapStart(len(v))
  6314. if e.h.Canonical {
  6315. v2 := make([]uint64, len(v))
  6316. var i int
  6317. for k, _ := range v {
  6318. v2[i] = uint64(k)
  6319. i++
  6320. }
  6321. sort.Sort(uintSlice(v2))
  6322. for _, k2 := range v2 {
  6323. if esep {
  6324. ee.WriteMapElemKey()
  6325. }
  6326. ee.EncodeUint(uint64(uint8(k2)))
  6327. if esep {
  6328. ee.WriteMapElemValue()
  6329. }
  6330. ee.EncodeBool(v[uint8(k2)])
  6331. }
  6332. } else {
  6333. for k2, v2 := range v {
  6334. if esep {
  6335. ee.WriteMapElemKey()
  6336. }
  6337. ee.EncodeUint(uint64(k2))
  6338. if esep {
  6339. ee.WriteMapElemValue()
  6340. }
  6341. ee.EncodeBool(v2)
  6342. }
  6343. }
  6344. ee.WriteMapEnd()
  6345. }
  6346. func (e *Encoder) fastpathEncMapUint16IntfR(f *codecFnInfo, rv reflect.Value) {
  6347. fastpathTV.EncMapUint16IntfV(rv2i(rv).(map[uint16]interface{}), e)
  6348. }
  6349. func (_ fastpathT) EncMapUint16IntfV(v map[uint16]interface{}, e *Encoder) {
  6350. if v == nil {
  6351. e.e.EncodeNil()
  6352. return
  6353. }
  6354. ee, esep := e.e, e.hh.hasElemSeparators()
  6355. ee.WriteMapStart(len(v))
  6356. if e.h.Canonical {
  6357. v2 := make([]uint64, len(v))
  6358. var i int
  6359. for k, _ := range v {
  6360. v2[i] = uint64(k)
  6361. i++
  6362. }
  6363. sort.Sort(uintSlice(v2))
  6364. for _, k2 := range v2 {
  6365. if esep {
  6366. ee.WriteMapElemKey()
  6367. }
  6368. ee.EncodeUint(uint64(uint16(k2)))
  6369. if esep {
  6370. ee.WriteMapElemValue()
  6371. }
  6372. e.encode(v[uint16(k2)])
  6373. }
  6374. } else {
  6375. for k2, v2 := range v {
  6376. if esep {
  6377. ee.WriteMapElemKey()
  6378. }
  6379. ee.EncodeUint(uint64(k2))
  6380. if esep {
  6381. ee.WriteMapElemValue()
  6382. }
  6383. e.encode(v2)
  6384. }
  6385. }
  6386. ee.WriteMapEnd()
  6387. }
  6388. func (e *Encoder) fastpathEncMapUint16StringR(f *codecFnInfo, rv reflect.Value) {
  6389. fastpathTV.EncMapUint16StringV(rv2i(rv).(map[uint16]string), e)
  6390. }
  6391. func (_ fastpathT) EncMapUint16StringV(v map[uint16]string, e *Encoder) {
  6392. if v == nil {
  6393. e.e.EncodeNil()
  6394. return
  6395. }
  6396. ee, esep := e.e, e.hh.hasElemSeparators()
  6397. ee.WriteMapStart(len(v))
  6398. if e.h.Canonical {
  6399. v2 := make([]uint64, len(v))
  6400. var i int
  6401. for k, _ := range v {
  6402. v2[i] = uint64(k)
  6403. i++
  6404. }
  6405. sort.Sort(uintSlice(v2))
  6406. for _, k2 := range v2 {
  6407. if esep {
  6408. ee.WriteMapElemKey()
  6409. }
  6410. ee.EncodeUint(uint64(uint16(k2)))
  6411. if esep {
  6412. ee.WriteMapElemValue()
  6413. }
  6414. ee.EncodeString(cUTF8, v[uint16(k2)])
  6415. }
  6416. } else {
  6417. for k2, v2 := range v {
  6418. if esep {
  6419. ee.WriteMapElemKey()
  6420. }
  6421. ee.EncodeUint(uint64(k2))
  6422. if esep {
  6423. ee.WriteMapElemValue()
  6424. }
  6425. ee.EncodeString(cUTF8, v2)
  6426. }
  6427. }
  6428. ee.WriteMapEnd()
  6429. }
  6430. func (e *Encoder) fastpathEncMapUint16UintR(f *codecFnInfo, rv reflect.Value) {
  6431. fastpathTV.EncMapUint16UintV(rv2i(rv).(map[uint16]uint), e)
  6432. }
  6433. func (_ fastpathT) EncMapUint16UintV(v map[uint16]uint, e *Encoder) {
  6434. if v == nil {
  6435. e.e.EncodeNil()
  6436. return
  6437. }
  6438. ee, esep := e.e, e.hh.hasElemSeparators()
  6439. ee.WriteMapStart(len(v))
  6440. if e.h.Canonical {
  6441. v2 := make([]uint64, len(v))
  6442. var i int
  6443. for k, _ := range v {
  6444. v2[i] = uint64(k)
  6445. i++
  6446. }
  6447. sort.Sort(uintSlice(v2))
  6448. for _, k2 := range v2 {
  6449. if esep {
  6450. ee.WriteMapElemKey()
  6451. }
  6452. ee.EncodeUint(uint64(uint16(k2)))
  6453. if esep {
  6454. ee.WriteMapElemValue()
  6455. }
  6456. ee.EncodeUint(uint64(v[uint16(k2)]))
  6457. }
  6458. } else {
  6459. for k2, v2 := range v {
  6460. if esep {
  6461. ee.WriteMapElemKey()
  6462. }
  6463. ee.EncodeUint(uint64(k2))
  6464. if esep {
  6465. ee.WriteMapElemValue()
  6466. }
  6467. ee.EncodeUint(uint64(v2))
  6468. }
  6469. }
  6470. ee.WriteMapEnd()
  6471. }
  6472. func (e *Encoder) fastpathEncMapUint16Uint8R(f *codecFnInfo, rv reflect.Value) {
  6473. fastpathTV.EncMapUint16Uint8V(rv2i(rv).(map[uint16]uint8), e)
  6474. }
  6475. func (_ fastpathT) EncMapUint16Uint8V(v map[uint16]uint8, e *Encoder) {
  6476. if v == nil {
  6477. e.e.EncodeNil()
  6478. return
  6479. }
  6480. ee, esep := e.e, e.hh.hasElemSeparators()
  6481. ee.WriteMapStart(len(v))
  6482. if e.h.Canonical {
  6483. v2 := make([]uint64, len(v))
  6484. var i int
  6485. for k, _ := range v {
  6486. v2[i] = uint64(k)
  6487. i++
  6488. }
  6489. sort.Sort(uintSlice(v2))
  6490. for _, k2 := range v2 {
  6491. if esep {
  6492. ee.WriteMapElemKey()
  6493. }
  6494. ee.EncodeUint(uint64(uint16(k2)))
  6495. if esep {
  6496. ee.WriteMapElemValue()
  6497. }
  6498. ee.EncodeUint(uint64(v[uint16(k2)]))
  6499. }
  6500. } else {
  6501. for k2, v2 := range v {
  6502. if esep {
  6503. ee.WriteMapElemKey()
  6504. }
  6505. ee.EncodeUint(uint64(k2))
  6506. if esep {
  6507. ee.WriteMapElemValue()
  6508. }
  6509. ee.EncodeUint(uint64(v2))
  6510. }
  6511. }
  6512. ee.WriteMapEnd()
  6513. }
  6514. func (e *Encoder) fastpathEncMapUint16Uint16R(f *codecFnInfo, rv reflect.Value) {
  6515. fastpathTV.EncMapUint16Uint16V(rv2i(rv).(map[uint16]uint16), e)
  6516. }
  6517. func (_ fastpathT) EncMapUint16Uint16V(v map[uint16]uint16, e *Encoder) {
  6518. if v == nil {
  6519. e.e.EncodeNil()
  6520. return
  6521. }
  6522. ee, esep := e.e, e.hh.hasElemSeparators()
  6523. ee.WriteMapStart(len(v))
  6524. if e.h.Canonical {
  6525. v2 := make([]uint64, len(v))
  6526. var i int
  6527. for k, _ := range v {
  6528. v2[i] = uint64(k)
  6529. i++
  6530. }
  6531. sort.Sort(uintSlice(v2))
  6532. for _, k2 := range v2 {
  6533. if esep {
  6534. ee.WriteMapElemKey()
  6535. }
  6536. ee.EncodeUint(uint64(uint16(k2)))
  6537. if esep {
  6538. ee.WriteMapElemValue()
  6539. }
  6540. ee.EncodeUint(uint64(v[uint16(k2)]))
  6541. }
  6542. } else {
  6543. for k2, v2 := range v {
  6544. if esep {
  6545. ee.WriteMapElemKey()
  6546. }
  6547. ee.EncodeUint(uint64(k2))
  6548. if esep {
  6549. ee.WriteMapElemValue()
  6550. }
  6551. ee.EncodeUint(uint64(v2))
  6552. }
  6553. }
  6554. ee.WriteMapEnd()
  6555. }
  6556. func (e *Encoder) fastpathEncMapUint16Uint32R(f *codecFnInfo, rv reflect.Value) {
  6557. fastpathTV.EncMapUint16Uint32V(rv2i(rv).(map[uint16]uint32), e)
  6558. }
  6559. func (_ fastpathT) EncMapUint16Uint32V(v map[uint16]uint32, e *Encoder) {
  6560. if v == nil {
  6561. e.e.EncodeNil()
  6562. return
  6563. }
  6564. ee, esep := e.e, e.hh.hasElemSeparators()
  6565. ee.WriteMapStart(len(v))
  6566. if e.h.Canonical {
  6567. v2 := make([]uint64, len(v))
  6568. var i int
  6569. for k, _ := range v {
  6570. v2[i] = uint64(k)
  6571. i++
  6572. }
  6573. sort.Sort(uintSlice(v2))
  6574. for _, k2 := range v2 {
  6575. if esep {
  6576. ee.WriteMapElemKey()
  6577. }
  6578. ee.EncodeUint(uint64(uint16(k2)))
  6579. if esep {
  6580. ee.WriteMapElemValue()
  6581. }
  6582. ee.EncodeUint(uint64(v[uint16(k2)]))
  6583. }
  6584. } else {
  6585. for k2, v2 := range v {
  6586. if esep {
  6587. ee.WriteMapElemKey()
  6588. }
  6589. ee.EncodeUint(uint64(k2))
  6590. if esep {
  6591. ee.WriteMapElemValue()
  6592. }
  6593. ee.EncodeUint(uint64(v2))
  6594. }
  6595. }
  6596. ee.WriteMapEnd()
  6597. }
  6598. func (e *Encoder) fastpathEncMapUint16Uint64R(f *codecFnInfo, rv reflect.Value) {
  6599. fastpathTV.EncMapUint16Uint64V(rv2i(rv).(map[uint16]uint64), e)
  6600. }
  6601. func (_ fastpathT) EncMapUint16Uint64V(v map[uint16]uint64, e *Encoder) {
  6602. if v == nil {
  6603. e.e.EncodeNil()
  6604. return
  6605. }
  6606. ee, esep := e.e, e.hh.hasElemSeparators()
  6607. ee.WriteMapStart(len(v))
  6608. if e.h.Canonical {
  6609. v2 := make([]uint64, len(v))
  6610. var i int
  6611. for k, _ := range v {
  6612. v2[i] = uint64(k)
  6613. i++
  6614. }
  6615. sort.Sort(uintSlice(v2))
  6616. for _, k2 := range v2 {
  6617. if esep {
  6618. ee.WriteMapElemKey()
  6619. }
  6620. ee.EncodeUint(uint64(uint16(k2)))
  6621. if esep {
  6622. ee.WriteMapElemValue()
  6623. }
  6624. ee.EncodeUint(uint64(v[uint16(k2)]))
  6625. }
  6626. } else {
  6627. for k2, v2 := range v {
  6628. if esep {
  6629. ee.WriteMapElemKey()
  6630. }
  6631. ee.EncodeUint(uint64(k2))
  6632. if esep {
  6633. ee.WriteMapElemValue()
  6634. }
  6635. ee.EncodeUint(uint64(v2))
  6636. }
  6637. }
  6638. ee.WriteMapEnd()
  6639. }
  6640. func (e *Encoder) fastpathEncMapUint16UintptrR(f *codecFnInfo, rv reflect.Value) {
  6641. fastpathTV.EncMapUint16UintptrV(rv2i(rv).(map[uint16]uintptr), e)
  6642. }
  6643. func (_ fastpathT) EncMapUint16UintptrV(v map[uint16]uintptr, e *Encoder) {
  6644. if v == nil {
  6645. e.e.EncodeNil()
  6646. return
  6647. }
  6648. ee, esep := e.e, e.hh.hasElemSeparators()
  6649. ee.WriteMapStart(len(v))
  6650. if e.h.Canonical {
  6651. v2 := make([]uint64, len(v))
  6652. var i int
  6653. for k, _ := range v {
  6654. v2[i] = uint64(k)
  6655. i++
  6656. }
  6657. sort.Sort(uintSlice(v2))
  6658. for _, k2 := range v2 {
  6659. if esep {
  6660. ee.WriteMapElemKey()
  6661. }
  6662. ee.EncodeUint(uint64(uint16(k2)))
  6663. if esep {
  6664. ee.WriteMapElemValue()
  6665. }
  6666. e.encode(v[uint16(k2)])
  6667. }
  6668. } else {
  6669. for k2, v2 := range v {
  6670. if esep {
  6671. ee.WriteMapElemKey()
  6672. }
  6673. ee.EncodeUint(uint64(k2))
  6674. if esep {
  6675. ee.WriteMapElemValue()
  6676. }
  6677. e.encode(v2)
  6678. }
  6679. }
  6680. ee.WriteMapEnd()
  6681. }
  6682. func (e *Encoder) fastpathEncMapUint16IntR(f *codecFnInfo, rv reflect.Value) {
  6683. fastpathTV.EncMapUint16IntV(rv2i(rv).(map[uint16]int), e)
  6684. }
  6685. func (_ fastpathT) EncMapUint16IntV(v map[uint16]int, e *Encoder) {
  6686. if v == nil {
  6687. e.e.EncodeNil()
  6688. return
  6689. }
  6690. ee, esep := e.e, e.hh.hasElemSeparators()
  6691. ee.WriteMapStart(len(v))
  6692. if e.h.Canonical {
  6693. v2 := make([]uint64, len(v))
  6694. var i int
  6695. for k, _ := range v {
  6696. v2[i] = uint64(k)
  6697. i++
  6698. }
  6699. sort.Sort(uintSlice(v2))
  6700. for _, k2 := range v2 {
  6701. if esep {
  6702. ee.WriteMapElemKey()
  6703. }
  6704. ee.EncodeUint(uint64(uint16(k2)))
  6705. if esep {
  6706. ee.WriteMapElemValue()
  6707. }
  6708. ee.EncodeInt(int64(v[uint16(k2)]))
  6709. }
  6710. } else {
  6711. for k2, v2 := range v {
  6712. if esep {
  6713. ee.WriteMapElemKey()
  6714. }
  6715. ee.EncodeUint(uint64(k2))
  6716. if esep {
  6717. ee.WriteMapElemValue()
  6718. }
  6719. ee.EncodeInt(int64(v2))
  6720. }
  6721. }
  6722. ee.WriteMapEnd()
  6723. }
  6724. func (e *Encoder) fastpathEncMapUint16Int8R(f *codecFnInfo, rv reflect.Value) {
  6725. fastpathTV.EncMapUint16Int8V(rv2i(rv).(map[uint16]int8), e)
  6726. }
  6727. func (_ fastpathT) EncMapUint16Int8V(v map[uint16]int8, e *Encoder) {
  6728. if v == nil {
  6729. e.e.EncodeNil()
  6730. return
  6731. }
  6732. ee, esep := e.e, e.hh.hasElemSeparators()
  6733. ee.WriteMapStart(len(v))
  6734. if e.h.Canonical {
  6735. v2 := make([]uint64, len(v))
  6736. var i int
  6737. for k, _ := range v {
  6738. v2[i] = uint64(k)
  6739. i++
  6740. }
  6741. sort.Sort(uintSlice(v2))
  6742. for _, k2 := range v2 {
  6743. if esep {
  6744. ee.WriteMapElemKey()
  6745. }
  6746. ee.EncodeUint(uint64(uint16(k2)))
  6747. if esep {
  6748. ee.WriteMapElemValue()
  6749. }
  6750. ee.EncodeInt(int64(v[uint16(k2)]))
  6751. }
  6752. } else {
  6753. for k2, v2 := range v {
  6754. if esep {
  6755. ee.WriteMapElemKey()
  6756. }
  6757. ee.EncodeUint(uint64(k2))
  6758. if esep {
  6759. ee.WriteMapElemValue()
  6760. }
  6761. ee.EncodeInt(int64(v2))
  6762. }
  6763. }
  6764. ee.WriteMapEnd()
  6765. }
  6766. func (e *Encoder) fastpathEncMapUint16Int16R(f *codecFnInfo, rv reflect.Value) {
  6767. fastpathTV.EncMapUint16Int16V(rv2i(rv).(map[uint16]int16), e)
  6768. }
  6769. func (_ fastpathT) EncMapUint16Int16V(v map[uint16]int16, e *Encoder) {
  6770. if v == nil {
  6771. e.e.EncodeNil()
  6772. return
  6773. }
  6774. ee, esep := e.e, e.hh.hasElemSeparators()
  6775. ee.WriteMapStart(len(v))
  6776. if e.h.Canonical {
  6777. v2 := make([]uint64, len(v))
  6778. var i int
  6779. for k, _ := range v {
  6780. v2[i] = uint64(k)
  6781. i++
  6782. }
  6783. sort.Sort(uintSlice(v2))
  6784. for _, k2 := range v2 {
  6785. if esep {
  6786. ee.WriteMapElemKey()
  6787. }
  6788. ee.EncodeUint(uint64(uint16(k2)))
  6789. if esep {
  6790. ee.WriteMapElemValue()
  6791. }
  6792. ee.EncodeInt(int64(v[uint16(k2)]))
  6793. }
  6794. } else {
  6795. for k2, v2 := range v {
  6796. if esep {
  6797. ee.WriteMapElemKey()
  6798. }
  6799. ee.EncodeUint(uint64(k2))
  6800. if esep {
  6801. ee.WriteMapElemValue()
  6802. }
  6803. ee.EncodeInt(int64(v2))
  6804. }
  6805. }
  6806. ee.WriteMapEnd()
  6807. }
  6808. func (e *Encoder) fastpathEncMapUint16Int32R(f *codecFnInfo, rv reflect.Value) {
  6809. fastpathTV.EncMapUint16Int32V(rv2i(rv).(map[uint16]int32), e)
  6810. }
  6811. func (_ fastpathT) EncMapUint16Int32V(v map[uint16]int32, e *Encoder) {
  6812. if v == nil {
  6813. e.e.EncodeNil()
  6814. return
  6815. }
  6816. ee, esep := e.e, e.hh.hasElemSeparators()
  6817. ee.WriteMapStart(len(v))
  6818. if e.h.Canonical {
  6819. v2 := make([]uint64, len(v))
  6820. var i int
  6821. for k, _ := range v {
  6822. v2[i] = uint64(k)
  6823. i++
  6824. }
  6825. sort.Sort(uintSlice(v2))
  6826. for _, k2 := range v2 {
  6827. if esep {
  6828. ee.WriteMapElemKey()
  6829. }
  6830. ee.EncodeUint(uint64(uint16(k2)))
  6831. if esep {
  6832. ee.WriteMapElemValue()
  6833. }
  6834. ee.EncodeInt(int64(v[uint16(k2)]))
  6835. }
  6836. } else {
  6837. for k2, v2 := range v {
  6838. if esep {
  6839. ee.WriteMapElemKey()
  6840. }
  6841. ee.EncodeUint(uint64(k2))
  6842. if esep {
  6843. ee.WriteMapElemValue()
  6844. }
  6845. ee.EncodeInt(int64(v2))
  6846. }
  6847. }
  6848. ee.WriteMapEnd()
  6849. }
  6850. func (e *Encoder) fastpathEncMapUint16Int64R(f *codecFnInfo, rv reflect.Value) {
  6851. fastpathTV.EncMapUint16Int64V(rv2i(rv).(map[uint16]int64), e)
  6852. }
  6853. func (_ fastpathT) EncMapUint16Int64V(v map[uint16]int64, e *Encoder) {
  6854. if v == nil {
  6855. e.e.EncodeNil()
  6856. return
  6857. }
  6858. ee, esep := e.e, e.hh.hasElemSeparators()
  6859. ee.WriteMapStart(len(v))
  6860. if e.h.Canonical {
  6861. v2 := make([]uint64, len(v))
  6862. var i int
  6863. for k, _ := range v {
  6864. v2[i] = uint64(k)
  6865. i++
  6866. }
  6867. sort.Sort(uintSlice(v2))
  6868. for _, k2 := range v2 {
  6869. if esep {
  6870. ee.WriteMapElemKey()
  6871. }
  6872. ee.EncodeUint(uint64(uint16(k2)))
  6873. if esep {
  6874. ee.WriteMapElemValue()
  6875. }
  6876. ee.EncodeInt(int64(v[uint16(k2)]))
  6877. }
  6878. } else {
  6879. for k2, v2 := range v {
  6880. if esep {
  6881. ee.WriteMapElemKey()
  6882. }
  6883. ee.EncodeUint(uint64(k2))
  6884. if esep {
  6885. ee.WriteMapElemValue()
  6886. }
  6887. ee.EncodeInt(int64(v2))
  6888. }
  6889. }
  6890. ee.WriteMapEnd()
  6891. }
  6892. func (e *Encoder) fastpathEncMapUint16Float32R(f *codecFnInfo, rv reflect.Value) {
  6893. fastpathTV.EncMapUint16Float32V(rv2i(rv).(map[uint16]float32), e)
  6894. }
  6895. func (_ fastpathT) EncMapUint16Float32V(v map[uint16]float32, e *Encoder) {
  6896. if v == nil {
  6897. e.e.EncodeNil()
  6898. return
  6899. }
  6900. ee, esep := e.e, e.hh.hasElemSeparators()
  6901. ee.WriteMapStart(len(v))
  6902. if e.h.Canonical {
  6903. v2 := make([]uint64, len(v))
  6904. var i int
  6905. for k, _ := range v {
  6906. v2[i] = uint64(k)
  6907. i++
  6908. }
  6909. sort.Sort(uintSlice(v2))
  6910. for _, k2 := range v2 {
  6911. if esep {
  6912. ee.WriteMapElemKey()
  6913. }
  6914. ee.EncodeUint(uint64(uint16(k2)))
  6915. if esep {
  6916. ee.WriteMapElemValue()
  6917. }
  6918. ee.EncodeFloat32(v[uint16(k2)])
  6919. }
  6920. } else {
  6921. for k2, v2 := range v {
  6922. if esep {
  6923. ee.WriteMapElemKey()
  6924. }
  6925. ee.EncodeUint(uint64(k2))
  6926. if esep {
  6927. ee.WriteMapElemValue()
  6928. }
  6929. ee.EncodeFloat32(v2)
  6930. }
  6931. }
  6932. ee.WriteMapEnd()
  6933. }
  6934. func (e *Encoder) fastpathEncMapUint16Float64R(f *codecFnInfo, rv reflect.Value) {
  6935. fastpathTV.EncMapUint16Float64V(rv2i(rv).(map[uint16]float64), e)
  6936. }
  6937. func (_ fastpathT) EncMapUint16Float64V(v map[uint16]float64, e *Encoder) {
  6938. if v == nil {
  6939. e.e.EncodeNil()
  6940. return
  6941. }
  6942. ee, esep := e.e, e.hh.hasElemSeparators()
  6943. ee.WriteMapStart(len(v))
  6944. if e.h.Canonical {
  6945. v2 := make([]uint64, len(v))
  6946. var i int
  6947. for k, _ := range v {
  6948. v2[i] = uint64(k)
  6949. i++
  6950. }
  6951. sort.Sort(uintSlice(v2))
  6952. for _, k2 := range v2 {
  6953. if esep {
  6954. ee.WriteMapElemKey()
  6955. }
  6956. ee.EncodeUint(uint64(uint16(k2)))
  6957. if esep {
  6958. ee.WriteMapElemValue()
  6959. }
  6960. ee.EncodeFloat64(v[uint16(k2)])
  6961. }
  6962. } else {
  6963. for k2, v2 := range v {
  6964. if esep {
  6965. ee.WriteMapElemKey()
  6966. }
  6967. ee.EncodeUint(uint64(k2))
  6968. if esep {
  6969. ee.WriteMapElemValue()
  6970. }
  6971. ee.EncodeFloat64(v2)
  6972. }
  6973. }
  6974. ee.WriteMapEnd()
  6975. }
  6976. func (e *Encoder) fastpathEncMapUint16BoolR(f *codecFnInfo, rv reflect.Value) {
  6977. fastpathTV.EncMapUint16BoolV(rv2i(rv).(map[uint16]bool), e)
  6978. }
  6979. func (_ fastpathT) EncMapUint16BoolV(v map[uint16]bool, e *Encoder) {
  6980. if v == nil {
  6981. e.e.EncodeNil()
  6982. return
  6983. }
  6984. ee, esep := e.e, e.hh.hasElemSeparators()
  6985. ee.WriteMapStart(len(v))
  6986. if e.h.Canonical {
  6987. v2 := make([]uint64, len(v))
  6988. var i int
  6989. for k, _ := range v {
  6990. v2[i] = uint64(k)
  6991. i++
  6992. }
  6993. sort.Sort(uintSlice(v2))
  6994. for _, k2 := range v2 {
  6995. if esep {
  6996. ee.WriteMapElemKey()
  6997. }
  6998. ee.EncodeUint(uint64(uint16(k2)))
  6999. if esep {
  7000. ee.WriteMapElemValue()
  7001. }
  7002. ee.EncodeBool(v[uint16(k2)])
  7003. }
  7004. } else {
  7005. for k2, v2 := range v {
  7006. if esep {
  7007. ee.WriteMapElemKey()
  7008. }
  7009. ee.EncodeUint(uint64(k2))
  7010. if esep {
  7011. ee.WriteMapElemValue()
  7012. }
  7013. ee.EncodeBool(v2)
  7014. }
  7015. }
  7016. ee.WriteMapEnd()
  7017. }
  7018. func (e *Encoder) fastpathEncMapUint32IntfR(f *codecFnInfo, rv reflect.Value) {
  7019. fastpathTV.EncMapUint32IntfV(rv2i(rv).(map[uint32]interface{}), e)
  7020. }
  7021. func (_ fastpathT) EncMapUint32IntfV(v map[uint32]interface{}, e *Encoder) {
  7022. if v == nil {
  7023. e.e.EncodeNil()
  7024. return
  7025. }
  7026. ee, esep := e.e, e.hh.hasElemSeparators()
  7027. ee.WriteMapStart(len(v))
  7028. if e.h.Canonical {
  7029. v2 := make([]uint64, len(v))
  7030. var i int
  7031. for k, _ := range v {
  7032. v2[i] = uint64(k)
  7033. i++
  7034. }
  7035. sort.Sort(uintSlice(v2))
  7036. for _, k2 := range v2 {
  7037. if esep {
  7038. ee.WriteMapElemKey()
  7039. }
  7040. ee.EncodeUint(uint64(uint32(k2)))
  7041. if esep {
  7042. ee.WriteMapElemValue()
  7043. }
  7044. e.encode(v[uint32(k2)])
  7045. }
  7046. } else {
  7047. for k2, v2 := range v {
  7048. if esep {
  7049. ee.WriteMapElemKey()
  7050. }
  7051. ee.EncodeUint(uint64(k2))
  7052. if esep {
  7053. ee.WriteMapElemValue()
  7054. }
  7055. e.encode(v2)
  7056. }
  7057. }
  7058. ee.WriteMapEnd()
  7059. }
  7060. func (e *Encoder) fastpathEncMapUint32StringR(f *codecFnInfo, rv reflect.Value) {
  7061. fastpathTV.EncMapUint32StringV(rv2i(rv).(map[uint32]string), e)
  7062. }
  7063. func (_ fastpathT) EncMapUint32StringV(v map[uint32]string, e *Encoder) {
  7064. if v == nil {
  7065. e.e.EncodeNil()
  7066. return
  7067. }
  7068. ee, esep := e.e, e.hh.hasElemSeparators()
  7069. ee.WriteMapStart(len(v))
  7070. if e.h.Canonical {
  7071. v2 := make([]uint64, len(v))
  7072. var i int
  7073. for k, _ := range v {
  7074. v2[i] = uint64(k)
  7075. i++
  7076. }
  7077. sort.Sort(uintSlice(v2))
  7078. for _, k2 := range v2 {
  7079. if esep {
  7080. ee.WriteMapElemKey()
  7081. }
  7082. ee.EncodeUint(uint64(uint32(k2)))
  7083. if esep {
  7084. ee.WriteMapElemValue()
  7085. }
  7086. ee.EncodeString(cUTF8, v[uint32(k2)])
  7087. }
  7088. } else {
  7089. for k2, v2 := range v {
  7090. if esep {
  7091. ee.WriteMapElemKey()
  7092. }
  7093. ee.EncodeUint(uint64(k2))
  7094. if esep {
  7095. ee.WriteMapElemValue()
  7096. }
  7097. ee.EncodeString(cUTF8, v2)
  7098. }
  7099. }
  7100. ee.WriteMapEnd()
  7101. }
  7102. func (e *Encoder) fastpathEncMapUint32UintR(f *codecFnInfo, rv reflect.Value) {
  7103. fastpathTV.EncMapUint32UintV(rv2i(rv).(map[uint32]uint), e)
  7104. }
  7105. func (_ fastpathT) EncMapUint32UintV(v map[uint32]uint, e *Encoder) {
  7106. if v == nil {
  7107. e.e.EncodeNil()
  7108. return
  7109. }
  7110. ee, esep := e.e, e.hh.hasElemSeparators()
  7111. ee.WriteMapStart(len(v))
  7112. if e.h.Canonical {
  7113. v2 := make([]uint64, len(v))
  7114. var i int
  7115. for k, _ := range v {
  7116. v2[i] = uint64(k)
  7117. i++
  7118. }
  7119. sort.Sort(uintSlice(v2))
  7120. for _, k2 := range v2 {
  7121. if esep {
  7122. ee.WriteMapElemKey()
  7123. }
  7124. ee.EncodeUint(uint64(uint32(k2)))
  7125. if esep {
  7126. ee.WriteMapElemValue()
  7127. }
  7128. ee.EncodeUint(uint64(v[uint32(k2)]))
  7129. }
  7130. } else {
  7131. for k2, v2 := range v {
  7132. if esep {
  7133. ee.WriteMapElemKey()
  7134. }
  7135. ee.EncodeUint(uint64(k2))
  7136. if esep {
  7137. ee.WriteMapElemValue()
  7138. }
  7139. ee.EncodeUint(uint64(v2))
  7140. }
  7141. }
  7142. ee.WriteMapEnd()
  7143. }
  7144. func (e *Encoder) fastpathEncMapUint32Uint8R(f *codecFnInfo, rv reflect.Value) {
  7145. fastpathTV.EncMapUint32Uint8V(rv2i(rv).(map[uint32]uint8), e)
  7146. }
  7147. func (_ fastpathT) EncMapUint32Uint8V(v map[uint32]uint8, e *Encoder) {
  7148. if v == nil {
  7149. e.e.EncodeNil()
  7150. return
  7151. }
  7152. ee, esep := e.e, e.hh.hasElemSeparators()
  7153. ee.WriteMapStart(len(v))
  7154. if e.h.Canonical {
  7155. v2 := make([]uint64, len(v))
  7156. var i int
  7157. for k, _ := range v {
  7158. v2[i] = uint64(k)
  7159. i++
  7160. }
  7161. sort.Sort(uintSlice(v2))
  7162. for _, k2 := range v2 {
  7163. if esep {
  7164. ee.WriteMapElemKey()
  7165. }
  7166. ee.EncodeUint(uint64(uint32(k2)))
  7167. if esep {
  7168. ee.WriteMapElemValue()
  7169. }
  7170. ee.EncodeUint(uint64(v[uint32(k2)]))
  7171. }
  7172. } else {
  7173. for k2, v2 := range v {
  7174. if esep {
  7175. ee.WriteMapElemKey()
  7176. }
  7177. ee.EncodeUint(uint64(k2))
  7178. if esep {
  7179. ee.WriteMapElemValue()
  7180. }
  7181. ee.EncodeUint(uint64(v2))
  7182. }
  7183. }
  7184. ee.WriteMapEnd()
  7185. }
  7186. func (e *Encoder) fastpathEncMapUint32Uint16R(f *codecFnInfo, rv reflect.Value) {
  7187. fastpathTV.EncMapUint32Uint16V(rv2i(rv).(map[uint32]uint16), e)
  7188. }
  7189. func (_ fastpathT) EncMapUint32Uint16V(v map[uint32]uint16, e *Encoder) {
  7190. if v == nil {
  7191. e.e.EncodeNil()
  7192. return
  7193. }
  7194. ee, esep := e.e, e.hh.hasElemSeparators()
  7195. ee.WriteMapStart(len(v))
  7196. if e.h.Canonical {
  7197. v2 := make([]uint64, len(v))
  7198. var i int
  7199. for k, _ := range v {
  7200. v2[i] = uint64(k)
  7201. i++
  7202. }
  7203. sort.Sort(uintSlice(v2))
  7204. for _, k2 := range v2 {
  7205. if esep {
  7206. ee.WriteMapElemKey()
  7207. }
  7208. ee.EncodeUint(uint64(uint32(k2)))
  7209. if esep {
  7210. ee.WriteMapElemValue()
  7211. }
  7212. ee.EncodeUint(uint64(v[uint32(k2)]))
  7213. }
  7214. } else {
  7215. for k2, v2 := range v {
  7216. if esep {
  7217. ee.WriteMapElemKey()
  7218. }
  7219. ee.EncodeUint(uint64(k2))
  7220. if esep {
  7221. ee.WriteMapElemValue()
  7222. }
  7223. ee.EncodeUint(uint64(v2))
  7224. }
  7225. }
  7226. ee.WriteMapEnd()
  7227. }
  7228. func (e *Encoder) fastpathEncMapUint32Uint32R(f *codecFnInfo, rv reflect.Value) {
  7229. fastpathTV.EncMapUint32Uint32V(rv2i(rv).(map[uint32]uint32), e)
  7230. }
  7231. func (_ fastpathT) EncMapUint32Uint32V(v map[uint32]uint32, e *Encoder) {
  7232. if v == nil {
  7233. e.e.EncodeNil()
  7234. return
  7235. }
  7236. ee, esep := e.e, e.hh.hasElemSeparators()
  7237. ee.WriteMapStart(len(v))
  7238. if e.h.Canonical {
  7239. v2 := make([]uint64, len(v))
  7240. var i int
  7241. for k, _ := range v {
  7242. v2[i] = uint64(k)
  7243. i++
  7244. }
  7245. sort.Sort(uintSlice(v2))
  7246. for _, k2 := range v2 {
  7247. if esep {
  7248. ee.WriteMapElemKey()
  7249. }
  7250. ee.EncodeUint(uint64(uint32(k2)))
  7251. if esep {
  7252. ee.WriteMapElemValue()
  7253. }
  7254. ee.EncodeUint(uint64(v[uint32(k2)]))
  7255. }
  7256. } else {
  7257. for k2, v2 := range v {
  7258. if esep {
  7259. ee.WriteMapElemKey()
  7260. }
  7261. ee.EncodeUint(uint64(k2))
  7262. if esep {
  7263. ee.WriteMapElemValue()
  7264. }
  7265. ee.EncodeUint(uint64(v2))
  7266. }
  7267. }
  7268. ee.WriteMapEnd()
  7269. }
  7270. func (e *Encoder) fastpathEncMapUint32Uint64R(f *codecFnInfo, rv reflect.Value) {
  7271. fastpathTV.EncMapUint32Uint64V(rv2i(rv).(map[uint32]uint64), e)
  7272. }
  7273. func (_ fastpathT) EncMapUint32Uint64V(v map[uint32]uint64, e *Encoder) {
  7274. if v == nil {
  7275. e.e.EncodeNil()
  7276. return
  7277. }
  7278. ee, esep := e.e, e.hh.hasElemSeparators()
  7279. ee.WriteMapStart(len(v))
  7280. if e.h.Canonical {
  7281. v2 := make([]uint64, len(v))
  7282. var i int
  7283. for k, _ := range v {
  7284. v2[i] = uint64(k)
  7285. i++
  7286. }
  7287. sort.Sort(uintSlice(v2))
  7288. for _, k2 := range v2 {
  7289. if esep {
  7290. ee.WriteMapElemKey()
  7291. }
  7292. ee.EncodeUint(uint64(uint32(k2)))
  7293. if esep {
  7294. ee.WriteMapElemValue()
  7295. }
  7296. ee.EncodeUint(uint64(v[uint32(k2)]))
  7297. }
  7298. } else {
  7299. for k2, v2 := range v {
  7300. if esep {
  7301. ee.WriteMapElemKey()
  7302. }
  7303. ee.EncodeUint(uint64(k2))
  7304. if esep {
  7305. ee.WriteMapElemValue()
  7306. }
  7307. ee.EncodeUint(uint64(v2))
  7308. }
  7309. }
  7310. ee.WriteMapEnd()
  7311. }
  7312. func (e *Encoder) fastpathEncMapUint32UintptrR(f *codecFnInfo, rv reflect.Value) {
  7313. fastpathTV.EncMapUint32UintptrV(rv2i(rv).(map[uint32]uintptr), e)
  7314. }
  7315. func (_ fastpathT) EncMapUint32UintptrV(v map[uint32]uintptr, e *Encoder) {
  7316. if v == nil {
  7317. e.e.EncodeNil()
  7318. return
  7319. }
  7320. ee, esep := e.e, e.hh.hasElemSeparators()
  7321. ee.WriteMapStart(len(v))
  7322. if e.h.Canonical {
  7323. v2 := make([]uint64, len(v))
  7324. var i int
  7325. for k, _ := range v {
  7326. v2[i] = uint64(k)
  7327. i++
  7328. }
  7329. sort.Sort(uintSlice(v2))
  7330. for _, k2 := range v2 {
  7331. if esep {
  7332. ee.WriteMapElemKey()
  7333. }
  7334. ee.EncodeUint(uint64(uint32(k2)))
  7335. if esep {
  7336. ee.WriteMapElemValue()
  7337. }
  7338. e.encode(v[uint32(k2)])
  7339. }
  7340. } else {
  7341. for k2, v2 := range v {
  7342. if esep {
  7343. ee.WriteMapElemKey()
  7344. }
  7345. ee.EncodeUint(uint64(k2))
  7346. if esep {
  7347. ee.WriteMapElemValue()
  7348. }
  7349. e.encode(v2)
  7350. }
  7351. }
  7352. ee.WriteMapEnd()
  7353. }
  7354. func (e *Encoder) fastpathEncMapUint32IntR(f *codecFnInfo, rv reflect.Value) {
  7355. fastpathTV.EncMapUint32IntV(rv2i(rv).(map[uint32]int), e)
  7356. }
  7357. func (_ fastpathT) EncMapUint32IntV(v map[uint32]int, e *Encoder) {
  7358. if v == nil {
  7359. e.e.EncodeNil()
  7360. return
  7361. }
  7362. ee, esep := e.e, e.hh.hasElemSeparators()
  7363. ee.WriteMapStart(len(v))
  7364. if e.h.Canonical {
  7365. v2 := make([]uint64, len(v))
  7366. var i int
  7367. for k, _ := range v {
  7368. v2[i] = uint64(k)
  7369. i++
  7370. }
  7371. sort.Sort(uintSlice(v2))
  7372. for _, k2 := range v2 {
  7373. if esep {
  7374. ee.WriteMapElemKey()
  7375. }
  7376. ee.EncodeUint(uint64(uint32(k2)))
  7377. if esep {
  7378. ee.WriteMapElemValue()
  7379. }
  7380. ee.EncodeInt(int64(v[uint32(k2)]))
  7381. }
  7382. } else {
  7383. for k2, v2 := range v {
  7384. if esep {
  7385. ee.WriteMapElemKey()
  7386. }
  7387. ee.EncodeUint(uint64(k2))
  7388. if esep {
  7389. ee.WriteMapElemValue()
  7390. }
  7391. ee.EncodeInt(int64(v2))
  7392. }
  7393. }
  7394. ee.WriteMapEnd()
  7395. }
  7396. func (e *Encoder) fastpathEncMapUint32Int8R(f *codecFnInfo, rv reflect.Value) {
  7397. fastpathTV.EncMapUint32Int8V(rv2i(rv).(map[uint32]int8), e)
  7398. }
  7399. func (_ fastpathT) EncMapUint32Int8V(v map[uint32]int8, e *Encoder) {
  7400. if v == nil {
  7401. e.e.EncodeNil()
  7402. return
  7403. }
  7404. ee, esep := e.e, e.hh.hasElemSeparators()
  7405. ee.WriteMapStart(len(v))
  7406. if e.h.Canonical {
  7407. v2 := make([]uint64, len(v))
  7408. var i int
  7409. for k, _ := range v {
  7410. v2[i] = uint64(k)
  7411. i++
  7412. }
  7413. sort.Sort(uintSlice(v2))
  7414. for _, k2 := range v2 {
  7415. if esep {
  7416. ee.WriteMapElemKey()
  7417. }
  7418. ee.EncodeUint(uint64(uint32(k2)))
  7419. if esep {
  7420. ee.WriteMapElemValue()
  7421. }
  7422. ee.EncodeInt(int64(v[uint32(k2)]))
  7423. }
  7424. } else {
  7425. for k2, v2 := range v {
  7426. if esep {
  7427. ee.WriteMapElemKey()
  7428. }
  7429. ee.EncodeUint(uint64(k2))
  7430. if esep {
  7431. ee.WriteMapElemValue()
  7432. }
  7433. ee.EncodeInt(int64(v2))
  7434. }
  7435. }
  7436. ee.WriteMapEnd()
  7437. }
  7438. func (e *Encoder) fastpathEncMapUint32Int16R(f *codecFnInfo, rv reflect.Value) {
  7439. fastpathTV.EncMapUint32Int16V(rv2i(rv).(map[uint32]int16), e)
  7440. }
  7441. func (_ fastpathT) EncMapUint32Int16V(v map[uint32]int16, e *Encoder) {
  7442. if v == nil {
  7443. e.e.EncodeNil()
  7444. return
  7445. }
  7446. ee, esep := e.e, e.hh.hasElemSeparators()
  7447. ee.WriteMapStart(len(v))
  7448. if e.h.Canonical {
  7449. v2 := make([]uint64, len(v))
  7450. var i int
  7451. for k, _ := range v {
  7452. v2[i] = uint64(k)
  7453. i++
  7454. }
  7455. sort.Sort(uintSlice(v2))
  7456. for _, k2 := range v2 {
  7457. if esep {
  7458. ee.WriteMapElemKey()
  7459. }
  7460. ee.EncodeUint(uint64(uint32(k2)))
  7461. if esep {
  7462. ee.WriteMapElemValue()
  7463. }
  7464. ee.EncodeInt(int64(v[uint32(k2)]))
  7465. }
  7466. } else {
  7467. for k2, v2 := range v {
  7468. if esep {
  7469. ee.WriteMapElemKey()
  7470. }
  7471. ee.EncodeUint(uint64(k2))
  7472. if esep {
  7473. ee.WriteMapElemValue()
  7474. }
  7475. ee.EncodeInt(int64(v2))
  7476. }
  7477. }
  7478. ee.WriteMapEnd()
  7479. }
  7480. func (e *Encoder) fastpathEncMapUint32Int32R(f *codecFnInfo, rv reflect.Value) {
  7481. fastpathTV.EncMapUint32Int32V(rv2i(rv).(map[uint32]int32), e)
  7482. }
  7483. func (_ fastpathT) EncMapUint32Int32V(v map[uint32]int32, e *Encoder) {
  7484. if v == nil {
  7485. e.e.EncodeNil()
  7486. return
  7487. }
  7488. ee, esep := e.e, e.hh.hasElemSeparators()
  7489. ee.WriteMapStart(len(v))
  7490. if e.h.Canonical {
  7491. v2 := make([]uint64, len(v))
  7492. var i int
  7493. for k, _ := range v {
  7494. v2[i] = uint64(k)
  7495. i++
  7496. }
  7497. sort.Sort(uintSlice(v2))
  7498. for _, k2 := range v2 {
  7499. if esep {
  7500. ee.WriteMapElemKey()
  7501. }
  7502. ee.EncodeUint(uint64(uint32(k2)))
  7503. if esep {
  7504. ee.WriteMapElemValue()
  7505. }
  7506. ee.EncodeInt(int64(v[uint32(k2)]))
  7507. }
  7508. } else {
  7509. for k2, v2 := range v {
  7510. if esep {
  7511. ee.WriteMapElemKey()
  7512. }
  7513. ee.EncodeUint(uint64(k2))
  7514. if esep {
  7515. ee.WriteMapElemValue()
  7516. }
  7517. ee.EncodeInt(int64(v2))
  7518. }
  7519. }
  7520. ee.WriteMapEnd()
  7521. }
  7522. func (e *Encoder) fastpathEncMapUint32Int64R(f *codecFnInfo, rv reflect.Value) {
  7523. fastpathTV.EncMapUint32Int64V(rv2i(rv).(map[uint32]int64), e)
  7524. }
  7525. func (_ fastpathT) EncMapUint32Int64V(v map[uint32]int64, e *Encoder) {
  7526. if v == nil {
  7527. e.e.EncodeNil()
  7528. return
  7529. }
  7530. ee, esep := e.e, e.hh.hasElemSeparators()
  7531. ee.WriteMapStart(len(v))
  7532. if e.h.Canonical {
  7533. v2 := make([]uint64, len(v))
  7534. var i int
  7535. for k, _ := range v {
  7536. v2[i] = uint64(k)
  7537. i++
  7538. }
  7539. sort.Sort(uintSlice(v2))
  7540. for _, k2 := range v2 {
  7541. if esep {
  7542. ee.WriteMapElemKey()
  7543. }
  7544. ee.EncodeUint(uint64(uint32(k2)))
  7545. if esep {
  7546. ee.WriteMapElemValue()
  7547. }
  7548. ee.EncodeInt(int64(v[uint32(k2)]))
  7549. }
  7550. } else {
  7551. for k2, v2 := range v {
  7552. if esep {
  7553. ee.WriteMapElemKey()
  7554. }
  7555. ee.EncodeUint(uint64(k2))
  7556. if esep {
  7557. ee.WriteMapElemValue()
  7558. }
  7559. ee.EncodeInt(int64(v2))
  7560. }
  7561. }
  7562. ee.WriteMapEnd()
  7563. }
  7564. func (e *Encoder) fastpathEncMapUint32Float32R(f *codecFnInfo, rv reflect.Value) {
  7565. fastpathTV.EncMapUint32Float32V(rv2i(rv).(map[uint32]float32), e)
  7566. }
  7567. func (_ fastpathT) EncMapUint32Float32V(v map[uint32]float32, e *Encoder) {
  7568. if v == nil {
  7569. e.e.EncodeNil()
  7570. return
  7571. }
  7572. ee, esep := e.e, e.hh.hasElemSeparators()
  7573. ee.WriteMapStart(len(v))
  7574. if e.h.Canonical {
  7575. v2 := make([]uint64, len(v))
  7576. var i int
  7577. for k, _ := range v {
  7578. v2[i] = uint64(k)
  7579. i++
  7580. }
  7581. sort.Sort(uintSlice(v2))
  7582. for _, k2 := range v2 {
  7583. if esep {
  7584. ee.WriteMapElemKey()
  7585. }
  7586. ee.EncodeUint(uint64(uint32(k2)))
  7587. if esep {
  7588. ee.WriteMapElemValue()
  7589. }
  7590. ee.EncodeFloat32(v[uint32(k2)])
  7591. }
  7592. } else {
  7593. for k2, v2 := range v {
  7594. if esep {
  7595. ee.WriteMapElemKey()
  7596. }
  7597. ee.EncodeUint(uint64(k2))
  7598. if esep {
  7599. ee.WriteMapElemValue()
  7600. }
  7601. ee.EncodeFloat32(v2)
  7602. }
  7603. }
  7604. ee.WriteMapEnd()
  7605. }
  7606. func (e *Encoder) fastpathEncMapUint32Float64R(f *codecFnInfo, rv reflect.Value) {
  7607. fastpathTV.EncMapUint32Float64V(rv2i(rv).(map[uint32]float64), e)
  7608. }
  7609. func (_ fastpathT) EncMapUint32Float64V(v map[uint32]float64, e *Encoder) {
  7610. if v == nil {
  7611. e.e.EncodeNil()
  7612. return
  7613. }
  7614. ee, esep := e.e, e.hh.hasElemSeparators()
  7615. ee.WriteMapStart(len(v))
  7616. if e.h.Canonical {
  7617. v2 := make([]uint64, len(v))
  7618. var i int
  7619. for k, _ := range v {
  7620. v2[i] = uint64(k)
  7621. i++
  7622. }
  7623. sort.Sort(uintSlice(v2))
  7624. for _, k2 := range v2 {
  7625. if esep {
  7626. ee.WriteMapElemKey()
  7627. }
  7628. ee.EncodeUint(uint64(uint32(k2)))
  7629. if esep {
  7630. ee.WriteMapElemValue()
  7631. }
  7632. ee.EncodeFloat64(v[uint32(k2)])
  7633. }
  7634. } else {
  7635. for k2, v2 := range v {
  7636. if esep {
  7637. ee.WriteMapElemKey()
  7638. }
  7639. ee.EncodeUint(uint64(k2))
  7640. if esep {
  7641. ee.WriteMapElemValue()
  7642. }
  7643. ee.EncodeFloat64(v2)
  7644. }
  7645. }
  7646. ee.WriteMapEnd()
  7647. }
  7648. func (e *Encoder) fastpathEncMapUint32BoolR(f *codecFnInfo, rv reflect.Value) {
  7649. fastpathTV.EncMapUint32BoolV(rv2i(rv).(map[uint32]bool), e)
  7650. }
  7651. func (_ fastpathT) EncMapUint32BoolV(v map[uint32]bool, e *Encoder) {
  7652. if v == nil {
  7653. e.e.EncodeNil()
  7654. return
  7655. }
  7656. ee, esep := e.e, e.hh.hasElemSeparators()
  7657. ee.WriteMapStart(len(v))
  7658. if e.h.Canonical {
  7659. v2 := make([]uint64, len(v))
  7660. var i int
  7661. for k, _ := range v {
  7662. v2[i] = uint64(k)
  7663. i++
  7664. }
  7665. sort.Sort(uintSlice(v2))
  7666. for _, k2 := range v2 {
  7667. if esep {
  7668. ee.WriteMapElemKey()
  7669. }
  7670. ee.EncodeUint(uint64(uint32(k2)))
  7671. if esep {
  7672. ee.WriteMapElemValue()
  7673. }
  7674. ee.EncodeBool(v[uint32(k2)])
  7675. }
  7676. } else {
  7677. for k2, v2 := range v {
  7678. if esep {
  7679. ee.WriteMapElemKey()
  7680. }
  7681. ee.EncodeUint(uint64(k2))
  7682. if esep {
  7683. ee.WriteMapElemValue()
  7684. }
  7685. ee.EncodeBool(v2)
  7686. }
  7687. }
  7688. ee.WriteMapEnd()
  7689. }
  7690. func (e *Encoder) fastpathEncMapUint64IntfR(f *codecFnInfo, rv reflect.Value) {
  7691. fastpathTV.EncMapUint64IntfV(rv2i(rv).(map[uint64]interface{}), e)
  7692. }
  7693. func (_ fastpathT) EncMapUint64IntfV(v map[uint64]interface{}, e *Encoder) {
  7694. if v == nil {
  7695. e.e.EncodeNil()
  7696. return
  7697. }
  7698. ee, esep := e.e, e.hh.hasElemSeparators()
  7699. ee.WriteMapStart(len(v))
  7700. if e.h.Canonical {
  7701. v2 := make([]uint64, len(v))
  7702. var i int
  7703. for k, _ := range v {
  7704. v2[i] = uint64(k)
  7705. i++
  7706. }
  7707. sort.Sort(uintSlice(v2))
  7708. for _, k2 := range v2 {
  7709. if esep {
  7710. ee.WriteMapElemKey()
  7711. }
  7712. ee.EncodeUint(uint64(uint64(k2)))
  7713. if esep {
  7714. ee.WriteMapElemValue()
  7715. }
  7716. e.encode(v[uint64(k2)])
  7717. }
  7718. } else {
  7719. for k2, v2 := range v {
  7720. if esep {
  7721. ee.WriteMapElemKey()
  7722. }
  7723. ee.EncodeUint(uint64(k2))
  7724. if esep {
  7725. ee.WriteMapElemValue()
  7726. }
  7727. e.encode(v2)
  7728. }
  7729. }
  7730. ee.WriteMapEnd()
  7731. }
  7732. func (e *Encoder) fastpathEncMapUint64StringR(f *codecFnInfo, rv reflect.Value) {
  7733. fastpathTV.EncMapUint64StringV(rv2i(rv).(map[uint64]string), e)
  7734. }
  7735. func (_ fastpathT) EncMapUint64StringV(v map[uint64]string, e *Encoder) {
  7736. if v == nil {
  7737. e.e.EncodeNil()
  7738. return
  7739. }
  7740. ee, esep := e.e, e.hh.hasElemSeparators()
  7741. ee.WriteMapStart(len(v))
  7742. if e.h.Canonical {
  7743. v2 := make([]uint64, len(v))
  7744. var i int
  7745. for k, _ := range v {
  7746. v2[i] = uint64(k)
  7747. i++
  7748. }
  7749. sort.Sort(uintSlice(v2))
  7750. for _, k2 := range v2 {
  7751. if esep {
  7752. ee.WriteMapElemKey()
  7753. }
  7754. ee.EncodeUint(uint64(uint64(k2)))
  7755. if esep {
  7756. ee.WriteMapElemValue()
  7757. }
  7758. ee.EncodeString(cUTF8, v[uint64(k2)])
  7759. }
  7760. } else {
  7761. for k2, v2 := range v {
  7762. if esep {
  7763. ee.WriteMapElemKey()
  7764. }
  7765. ee.EncodeUint(uint64(k2))
  7766. if esep {
  7767. ee.WriteMapElemValue()
  7768. }
  7769. ee.EncodeString(cUTF8, v2)
  7770. }
  7771. }
  7772. ee.WriteMapEnd()
  7773. }
  7774. func (e *Encoder) fastpathEncMapUint64UintR(f *codecFnInfo, rv reflect.Value) {
  7775. fastpathTV.EncMapUint64UintV(rv2i(rv).(map[uint64]uint), e)
  7776. }
  7777. func (_ fastpathT) EncMapUint64UintV(v map[uint64]uint, e *Encoder) {
  7778. if v == nil {
  7779. e.e.EncodeNil()
  7780. return
  7781. }
  7782. ee, esep := e.e, e.hh.hasElemSeparators()
  7783. ee.WriteMapStart(len(v))
  7784. if e.h.Canonical {
  7785. v2 := make([]uint64, len(v))
  7786. var i int
  7787. for k, _ := range v {
  7788. v2[i] = uint64(k)
  7789. i++
  7790. }
  7791. sort.Sort(uintSlice(v2))
  7792. for _, k2 := range v2 {
  7793. if esep {
  7794. ee.WriteMapElemKey()
  7795. }
  7796. ee.EncodeUint(uint64(uint64(k2)))
  7797. if esep {
  7798. ee.WriteMapElemValue()
  7799. }
  7800. ee.EncodeUint(uint64(v[uint64(k2)]))
  7801. }
  7802. } else {
  7803. for k2, v2 := range v {
  7804. if esep {
  7805. ee.WriteMapElemKey()
  7806. }
  7807. ee.EncodeUint(uint64(k2))
  7808. if esep {
  7809. ee.WriteMapElemValue()
  7810. }
  7811. ee.EncodeUint(uint64(v2))
  7812. }
  7813. }
  7814. ee.WriteMapEnd()
  7815. }
  7816. func (e *Encoder) fastpathEncMapUint64Uint8R(f *codecFnInfo, rv reflect.Value) {
  7817. fastpathTV.EncMapUint64Uint8V(rv2i(rv).(map[uint64]uint8), e)
  7818. }
  7819. func (_ fastpathT) EncMapUint64Uint8V(v map[uint64]uint8, e *Encoder) {
  7820. if v == nil {
  7821. e.e.EncodeNil()
  7822. return
  7823. }
  7824. ee, esep := e.e, e.hh.hasElemSeparators()
  7825. ee.WriteMapStart(len(v))
  7826. if e.h.Canonical {
  7827. v2 := make([]uint64, len(v))
  7828. var i int
  7829. for k, _ := range v {
  7830. v2[i] = uint64(k)
  7831. i++
  7832. }
  7833. sort.Sort(uintSlice(v2))
  7834. for _, k2 := range v2 {
  7835. if esep {
  7836. ee.WriteMapElemKey()
  7837. }
  7838. ee.EncodeUint(uint64(uint64(k2)))
  7839. if esep {
  7840. ee.WriteMapElemValue()
  7841. }
  7842. ee.EncodeUint(uint64(v[uint64(k2)]))
  7843. }
  7844. } else {
  7845. for k2, v2 := range v {
  7846. if esep {
  7847. ee.WriteMapElemKey()
  7848. }
  7849. ee.EncodeUint(uint64(k2))
  7850. if esep {
  7851. ee.WriteMapElemValue()
  7852. }
  7853. ee.EncodeUint(uint64(v2))
  7854. }
  7855. }
  7856. ee.WriteMapEnd()
  7857. }
  7858. func (e *Encoder) fastpathEncMapUint64Uint16R(f *codecFnInfo, rv reflect.Value) {
  7859. fastpathTV.EncMapUint64Uint16V(rv2i(rv).(map[uint64]uint16), e)
  7860. }
  7861. func (_ fastpathT) EncMapUint64Uint16V(v map[uint64]uint16, e *Encoder) {
  7862. if v == nil {
  7863. e.e.EncodeNil()
  7864. return
  7865. }
  7866. ee, esep := e.e, e.hh.hasElemSeparators()
  7867. ee.WriteMapStart(len(v))
  7868. if e.h.Canonical {
  7869. v2 := make([]uint64, len(v))
  7870. var i int
  7871. for k, _ := range v {
  7872. v2[i] = uint64(k)
  7873. i++
  7874. }
  7875. sort.Sort(uintSlice(v2))
  7876. for _, k2 := range v2 {
  7877. if esep {
  7878. ee.WriteMapElemKey()
  7879. }
  7880. ee.EncodeUint(uint64(uint64(k2)))
  7881. if esep {
  7882. ee.WriteMapElemValue()
  7883. }
  7884. ee.EncodeUint(uint64(v[uint64(k2)]))
  7885. }
  7886. } else {
  7887. for k2, v2 := range v {
  7888. if esep {
  7889. ee.WriteMapElemKey()
  7890. }
  7891. ee.EncodeUint(uint64(k2))
  7892. if esep {
  7893. ee.WriteMapElemValue()
  7894. }
  7895. ee.EncodeUint(uint64(v2))
  7896. }
  7897. }
  7898. ee.WriteMapEnd()
  7899. }
  7900. func (e *Encoder) fastpathEncMapUint64Uint32R(f *codecFnInfo, rv reflect.Value) {
  7901. fastpathTV.EncMapUint64Uint32V(rv2i(rv).(map[uint64]uint32), e)
  7902. }
  7903. func (_ fastpathT) EncMapUint64Uint32V(v map[uint64]uint32, e *Encoder) {
  7904. if v == nil {
  7905. e.e.EncodeNil()
  7906. return
  7907. }
  7908. ee, esep := e.e, e.hh.hasElemSeparators()
  7909. ee.WriteMapStart(len(v))
  7910. if e.h.Canonical {
  7911. v2 := make([]uint64, len(v))
  7912. var i int
  7913. for k, _ := range v {
  7914. v2[i] = uint64(k)
  7915. i++
  7916. }
  7917. sort.Sort(uintSlice(v2))
  7918. for _, k2 := range v2 {
  7919. if esep {
  7920. ee.WriteMapElemKey()
  7921. }
  7922. ee.EncodeUint(uint64(uint64(k2)))
  7923. if esep {
  7924. ee.WriteMapElemValue()
  7925. }
  7926. ee.EncodeUint(uint64(v[uint64(k2)]))
  7927. }
  7928. } else {
  7929. for k2, v2 := range v {
  7930. if esep {
  7931. ee.WriteMapElemKey()
  7932. }
  7933. ee.EncodeUint(uint64(k2))
  7934. if esep {
  7935. ee.WriteMapElemValue()
  7936. }
  7937. ee.EncodeUint(uint64(v2))
  7938. }
  7939. }
  7940. ee.WriteMapEnd()
  7941. }
  7942. func (e *Encoder) fastpathEncMapUint64Uint64R(f *codecFnInfo, rv reflect.Value) {
  7943. fastpathTV.EncMapUint64Uint64V(rv2i(rv).(map[uint64]uint64), e)
  7944. }
  7945. func (_ fastpathT) EncMapUint64Uint64V(v map[uint64]uint64, e *Encoder) {
  7946. if v == nil {
  7947. e.e.EncodeNil()
  7948. return
  7949. }
  7950. ee, esep := e.e, e.hh.hasElemSeparators()
  7951. ee.WriteMapStart(len(v))
  7952. if e.h.Canonical {
  7953. v2 := make([]uint64, len(v))
  7954. var i int
  7955. for k, _ := range v {
  7956. v2[i] = uint64(k)
  7957. i++
  7958. }
  7959. sort.Sort(uintSlice(v2))
  7960. for _, k2 := range v2 {
  7961. if esep {
  7962. ee.WriteMapElemKey()
  7963. }
  7964. ee.EncodeUint(uint64(uint64(k2)))
  7965. if esep {
  7966. ee.WriteMapElemValue()
  7967. }
  7968. ee.EncodeUint(uint64(v[uint64(k2)]))
  7969. }
  7970. } else {
  7971. for k2, v2 := range v {
  7972. if esep {
  7973. ee.WriteMapElemKey()
  7974. }
  7975. ee.EncodeUint(uint64(k2))
  7976. if esep {
  7977. ee.WriteMapElemValue()
  7978. }
  7979. ee.EncodeUint(uint64(v2))
  7980. }
  7981. }
  7982. ee.WriteMapEnd()
  7983. }
  7984. func (e *Encoder) fastpathEncMapUint64UintptrR(f *codecFnInfo, rv reflect.Value) {
  7985. fastpathTV.EncMapUint64UintptrV(rv2i(rv).(map[uint64]uintptr), e)
  7986. }
  7987. func (_ fastpathT) EncMapUint64UintptrV(v map[uint64]uintptr, e *Encoder) {
  7988. if v == nil {
  7989. e.e.EncodeNil()
  7990. return
  7991. }
  7992. ee, esep := e.e, e.hh.hasElemSeparators()
  7993. ee.WriteMapStart(len(v))
  7994. if e.h.Canonical {
  7995. v2 := make([]uint64, len(v))
  7996. var i int
  7997. for k, _ := range v {
  7998. v2[i] = uint64(k)
  7999. i++
  8000. }
  8001. sort.Sort(uintSlice(v2))
  8002. for _, k2 := range v2 {
  8003. if esep {
  8004. ee.WriteMapElemKey()
  8005. }
  8006. ee.EncodeUint(uint64(uint64(k2)))
  8007. if esep {
  8008. ee.WriteMapElemValue()
  8009. }
  8010. e.encode(v[uint64(k2)])
  8011. }
  8012. } else {
  8013. for k2, v2 := range v {
  8014. if esep {
  8015. ee.WriteMapElemKey()
  8016. }
  8017. ee.EncodeUint(uint64(k2))
  8018. if esep {
  8019. ee.WriteMapElemValue()
  8020. }
  8021. e.encode(v2)
  8022. }
  8023. }
  8024. ee.WriteMapEnd()
  8025. }
  8026. func (e *Encoder) fastpathEncMapUint64IntR(f *codecFnInfo, rv reflect.Value) {
  8027. fastpathTV.EncMapUint64IntV(rv2i(rv).(map[uint64]int), e)
  8028. }
  8029. func (_ fastpathT) EncMapUint64IntV(v map[uint64]int, e *Encoder) {
  8030. if v == nil {
  8031. e.e.EncodeNil()
  8032. return
  8033. }
  8034. ee, esep := e.e, e.hh.hasElemSeparators()
  8035. ee.WriteMapStart(len(v))
  8036. if e.h.Canonical {
  8037. v2 := make([]uint64, len(v))
  8038. var i int
  8039. for k, _ := range v {
  8040. v2[i] = uint64(k)
  8041. i++
  8042. }
  8043. sort.Sort(uintSlice(v2))
  8044. for _, k2 := range v2 {
  8045. if esep {
  8046. ee.WriteMapElemKey()
  8047. }
  8048. ee.EncodeUint(uint64(uint64(k2)))
  8049. if esep {
  8050. ee.WriteMapElemValue()
  8051. }
  8052. ee.EncodeInt(int64(v[uint64(k2)]))
  8053. }
  8054. } else {
  8055. for k2, v2 := range v {
  8056. if esep {
  8057. ee.WriteMapElemKey()
  8058. }
  8059. ee.EncodeUint(uint64(k2))
  8060. if esep {
  8061. ee.WriteMapElemValue()
  8062. }
  8063. ee.EncodeInt(int64(v2))
  8064. }
  8065. }
  8066. ee.WriteMapEnd()
  8067. }
  8068. func (e *Encoder) fastpathEncMapUint64Int8R(f *codecFnInfo, rv reflect.Value) {
  8069. fastpathTV.EncMapUint64Int8V(rv2i(rv).(map[uint64]int8), e)
  8070. }
  8071. func (_ fastpathT) EncMapUint64Int8V(v map[uint64]int8, e *Encoder) {
  8072. if v == nil {
  8073. e.e.EncodeNil()
  8074. return
  8075. }
  8076. ee, esep := e.e, e.hh.hasElemSeparators()
  8077. ee.WriteMapStart(len(v))
  8078. if e.h.Canonical {
  8079. v2 := make([]uint64, len(v))
  8080. var i int
  8081. for k, _ := range v {
  8082. v2[i] = uint64(k)
  8083. i++
  8084. }
  8085. sort.Sort(uintSlice(v2))
  8086. for _, k2 := range v2 {
  8087. if esep {
  8088. ee.WriteMapElemKey()
  8089. }
  8090. ee.EncodeUint(uint64(uint64(k2)))
  8091. if esep {
  8092. ee.WriteMapElemValue()
  8093. }
  8094. ee.EncodeInt(int64(v[uint64(k2)]))
  8095. }
  8096. } else {
  8097. for k2, v2 := range v {
  8098. if esep {
  8099. ee.WriteMapElemKey()
  8100. }
  8101. ee.EncodeUint(uint64(k2))
  8102. if esep {
  8103. ee.WriteMapElemValue()
  8104. }
  8105. ee.EncodeInt(int64(v2))
  8106. }
  8107. }
  8108. ee.WriteMapEnd()
  8109. }
  8110. func (e *Encoder) fastpathEncMapUint64Int16R(f *codecFnInfo, rv reflect.Value) {
  8111. fastpathTV.EncMapUint64Int16V(rv2i(rv).(map[uint64]int16), e)
  8112. }
  8113. func (_ fastpathT) EncMapUint64Int16V(v map[uint64]int16, e *Encoder) {
  8114. if v == nil {
  8115. e.e.EncodeNil()
  8116. return
  8117. }
  8118. ee, esep := e.e, e.hh.hasElemSeparators()
  8119. ee.WriteMapStart(len(v))
  8120. if e.h.Canonical {
  8121. v2 := make([]uint64, len(v))
  8122. var i int
  8123. for k, _ := range v {
  8124. v2[i] = uint64(k)
  8125. i++
  8126. }
  8127. sort.Sort(uintSlice(v2))
  8128. for _, k2 := range v2 {
  8129. if esep {
  8130. ee.WriteMapElemKey()
  8131. }
  8132. ee.EncodeUint(uint64(uint64(k2)))
  8133. if esep {
  8134. ee.WriteMapElemValue()
  8135. }
  8136. ee.EncodeInt(int64(v[uint64(k2)]))
  8137. }
  8138. } else {
  8139. for k2, v2 := range v {
  8140. if esep {
  8141. ee.WriteMapElemKey()
  8142. }
  8143. ee.EncodeUint(uint64(k2))
  8144. if esep {
  8145. ee.WriteMapElemValue()
  8146. }
  8147. ee.EncodeInt(int64(v2))
  8148. }
  8149. }
  8150. ee.WriteMapEnd()
  8151. }
  8152. func (e *Encoder) fastpathEncMapUint64Int32R(f *codecFnInfo, rv reflect.Value) {
  8153. fastpathTV.EncMapUint64Int32V(rv2i(rv).(map[uint64]int32), e)
  8154. }
  8155. func (_ fastpathT) EncMapUint64Int32V(v map[uint64]int32, e *Encoder) {
  8156. if v == nil {
  8157. e.e.EncodeNil()
  8158. return
  8159. }
  8160. ee, esep := e.e, e.hh.hasElemSeparators()
  8161. ee.WriteMapStart(len(v))
  8162. if e.h.Canonical {
  8163. v2 := make([]uint64, len(v))
  8164. var i int
  8165. for k, _ := range v {
  8166. v2[i] = uint64(k)
  8167. i++
  8168. }
  8169. sort.Sort(uintSlice(v2))
  8170. for _, k2 := range v2 {
  8171. if esep {
  8172. ee.WriteMapElemKey()
  8173. }
  8174. ee.EncodeUint(uint64(uint64(k2)))
  8175. if esep {
  8176. ee.WriteMapElemValue()
  8177. }
  8178. ee.EncodeInt(int64(v[uint64(k2)]))
  8179. }
  8180. } else {
  8181. for k2, v2 := range v {
  8182. if esep {
  8183. ee.WriteMapElemKey()
  8184. }
  8185. ee.EncodeUint(uint64(k2))
  8186. if esep {
  8187. ee.WriteMapElemValue()
  8188. }
  8189. ee.EncodeInt(int64(v2))
  8190. }
  8191. }
  8192. ee.WriteMapEnd()
  8193. }
  8194. func (e *Encoder) fastpathEncMapUint64Int64R(f *codecFnInfo, rv reflect.Value) {
  8195. fastpathTV.EncMapUint64Int64V(rv2i(rv).(map[uint64]int64), e)
  8196. }
  8197. func (_ fastpathT) EncMapUint64Int64V(v map[uint64]int64, e *Encoder) {
  8198. if v == nil {
  8199. e.e.EncodeNil()
  8200. return
  8201. }
  8202. ee, esep := e.e, e.hh.hasElemSeparators()
  8203. ee.WriteMapStart(len(v))
  8204. if e.h.Canonical {
  8205. v2 := make([]uint64, len(v))
  8206. var i int
  8207. for k, _ := range v {
  8208. v2[i] = uint64(k)
  8209. i++
  8210. }
  8211. sort.Sort(uintSlice(v2))
  8212. for _, k2 := range v2 {
  8213. if esep {
  8214. ee.WriteMapElemKey()
  8215. }
  8216. ee.EncodeUint(uint64(uint64(k2)))
  8217. if esep {
  8218. ee.WriteMapElemValue()
  8219. }
  8220. ee.EncodeInt(int64(v[uint64(k2)]))
  8221. }
  8222. } else {
  8223. for k2, v2 := range v {
  8224. if esep {
  8225. ee.WriteMapElemKey()
  8226. }
  8227. ee.EncodeUint(uint64(k2))
  8228. if esep {
  8229. ee.WriteMapElemValue()
  8230. }
  8231. ee.EncodeInt(int64(v2))
  8232. }
  8233. }
  8234. ee.WriteMapEnd()
  8235. }
  8236. func (e *Encoder) fastpathEncMapUint64Float32R(f *codecFnInfo, rv reflect.Value) {
  8237. fastpathTV.EncMapUint64Float32V(rv2i(rv).(map[uint64]float32), e)
  8238. }
  8239. func (_ fastpathT) EncMapUint64Float32V(v map[uint64]float32, e *Encoder) {
  8240. if v == nil {
  8241. e.e.EncodeNil()
  8242. return
  8243. }
  8244. ee, esep := e.e, e.hh.hasElemSeparators()
  8245. ee.WriteMapStart(len(v))
  8246. if e.h.Canonical {
  8247. v2 := make([]uint64, len(v))
  8248. var i int
  8249. for k, _ := range v {
  8250. v2[i] = uint64(k)
  8251. i++
  8252. }
  8253. sort.Sort(uintSlice(v2))
  8254. for _, k2 := range v2 {
  8255. if esep {
  8256. ee.WriteMapElemKey()
  8257. }
  8258. ee.EncodeUint(uint64(uint64(k2)))
  8259. if esep {
  8260. ee.WriteMapElemValue()
  8261. }
  8262. ee.EncodeFloat32(v[uint64(k2)])
  8263. }
  8264. } else {
  8265. for k2, v2 := range v {
  8266. if esep {
  8267. ee.WriteMapElemKey()
  8268. }
  8269. ee.EncodeUint(uint64(k2))
  8270. if esep {
  8271. ee.WriteMapElemValue()
  8272. }
  8273. ee.EncodeFloat32(v2)
  8274. }
  8275. }
  8276. ee.WriteMapEnd()
  8277. }
  8278. func (e *Encoder) fastpathEncMapUint64Float64R(f *codecFnInfo, rv reflect.Value) {
  8279. fastpathTV.EncMapUint64Float64V(rv2i(rv).(map[uint64]float64), e)
  8280. }
  8281. func (_ fastpathT) EncMapUint64Float64V(v map[uint64]float64, e *Encoder) {
  8282. if v == nil {
  8283. e.e.EncodeNil()
  8284. return
  8285. }
  8286. ee, esep := e.e, e.hh.hasElemSeparators()
  8287. ee.WriteMapStart(len(v))
  8288. if e.h.Canonical {
  8289. v2 := make([]uint64, len(v))
  8290. var i int
  8291. for k, _ := range v {
  8292. v2[i] = uint64(k)
  8293. i++
  8294. }
  8295. sort.Sort(uintSlice(v2))
  8296. for _, k2 := range v2 {
  8297. if esep {
  8298. ee.WriteMapElemKey()
  8299. }
  8300. ee.EncodeUint(uint64(uint64(k2)))
  8301. if esep {
  8302. ee.WriteMapElemValue()
  8303. }
  8304. ee.EncodeFloat64(v[uint64(k2)])
  8305. }
  8306. } else {
  8307. for k2, v2 := range v {
  8308. if esep {
  8309. ee.WriteMapElemKey()
  8310. }
  8311. ee.EncodeUint(uint64(k2))
  8312. if esep {
  8313. ee.WriteMapElemValue()
  8314. }
  8315. ee.EncodeFloat64(v2)
  8316. }
  8317. }
  8318. ee.WriteMapEnd()
  8319. }
  8320. func (e *Encoder) fastpathEncMapUint64BoolR(f *codecFnInfo, rv reflect.Value) {
  8321. fastpathTV.EncMapUint64BoolV(rv2i(rv).(map[uint64]bool), e)
  8322. }
  8323. func (_ fastpathT) EncMapUint64BoolV(v map[uint64]bool, e *Encoder) {
  8324. if v == nil {
  8325. e.e.EncodeNil()
  8326. return
  8327. }
  8328. ee, esep := e.e, e.hh.hasElemSeparators()
  8329. ee.WriteMapStart(len(v))
  8330. if e.h.Canonical {
  8331. v2 := make([]uint64, len(v))
  8332. var i int
  8333. for k, _ := range v {
  8334. v2[i] = uint64(k)
  8335. i++
  8336. }
  8337. sort.Sort(uintSlice(v2))
  8338. for _, k2 := range v2 {
  8339. if esep {
  8340. ee.WriteMapElemKey()
  8341. }
  8342. ee.EncodeUint(uint64(uint64(k2)))
  8343. if esep {
  8344. ee.WriteMapElemValue()
  8345. }
  8346. ee.EncodeBool(v[uint64(k2)])
  8347. }
  8348. } else {
  8349. for k2, v2 := range v {
  8350. if esep {
  8351. ee.WriteMapElemKey()
  8352. }
  8353. ee.EncodeUint(uint64(k2))
  8354. if esep {
  8355. ee.WriteMapElemValue()
  8356. }
  8357. ee.EncodeBool(v2)
  8358. }
  8359. }
  8360. ee.WriteMapEnd()
  8361. }
  8362. func (e *Encoder) fastpathEncMapUintptrIntfR(f *codecFnInfo, rv reflect.Value) {
  8363. fastpathTV.EncMapUintptrIntfV(rv2i(rv).(map[uintptr]interface{}), e)
  8364. }
  8365. func (_ fastpathT) EncMapUintptrIntfV(v map[uintptr]interface{}, e *Encoder) {
  8366. if v == nil {
  8367. e.e.EncodeNil()
  8368. return
  8369. }
  8370. ee, esep := e.e, e.hh.hasElemSeparators()
  8371. ee.WriteMapStart(len(v))
  8372. if e.h.Canonical {
  8373. v2 := make([]uint64, len(v))
  8374. var i int
  8375. for k, _ := range v {
  8376. v2[i] = uint64(k)
  8377. i++
  8378. }
  8379. sort.Sort(uintSlice(v2))
  8380. for _, k2 := range v2 {
  8381. if esep {
  8382. ee.WriteMapElemKey()
  8383. }
  8384. e.encode(uintptr(k2))
  8385. if esep {
  8386. ee.WriteMapElemValue()
  8387. }
  8388. e.encode(v[uintptr(k2)])
  8389. }
  8390. } else {
  8391. for k2, v2 := range v {
  8392. if esep {
  8393. ee.WriteMapElemKey()
  8394. }
  8395. e.encode(k2)
  8396. if esep {
  8397. ee.WriteMapElemValue()
  8398. }
  8399. e.encode(v2)
  8400. }
  8401. }
  8402. ee.WriteMapEnd()
  8403. }
  8404. func (e *Encoder) fastpathEncMapUintptrStringR(f *codecFnInfo, rv reflect.Value) {
  8405. fastpathTV.EncMapUintptrStringV(rv2i(rv).(map[uintptr]string), e)
  8406. }
  8407. func (_ fastpathT) EncMapUintptrStringV(v map[uintptr]string, e *Encoder) {
  8408. if v == nil {
  8409. e.e.EncodeNil()
  8410. return
  8411. }
  8412. ee, esep := e.e, e.hh.hasElemSeparators()
  8413. ee.WriteMapStart(len(v))
  8414. if e.h.Canonical {
  8415. v2 := make([]uint64, len(v))
  8416. var i int
  8417. for k, _ := range v {
  8418. v2[i] = uint64(k)
  8419. i++
  8420. }
  8421. sort.Sort(uintSlice(v2))
  8422. for _, k2 := range v2 {
  8423. if esep {
  8424. ee.WriteMapElemKey()
  8425. }
  8426. e.encode(uintptr(k2))
  8427. if esep {
  8428. ee.WriteMapElemValue()
  8429. }
  8430. ee.EncodeString(cUTF8, v[uintptr(k2)])
  8431. }
  8432. } else {
  8433. for k2, v2 := range v {
  8434. if esep {
  8435. ee.WriteMapElemKey()
  8436. }
  8437. e.encode(k2)
  8438. if esep {
  8439. ee.WriteMapElemValue()
  8440. }
  8441. ee.EncodeString(cUTF8, v2)
  8442. }
  8443. }
  8444. ee.WriteMapEnd()
  8445. }
  8446. func (e *Encoder) fastpathEncMapUintptrUintR(f *codecFnInfo, rv reflect.Value) {
  8447. fastpathTV.EncMapUintptrUintV(rv2i(rv).(map[uintptr]uint), e)
  8448. }
  8449. func (_ fastpathT) EncMapUintptrUintV(v map[uintptr]uint, e *Encoder) {
  8450. if v == nil {
  8451. e.e.EncodeNil()
  8452. return
  8453. }
  8454. ee, esep := e.e, e.hh.hasElemSeparators()
  8455. ee.WriteMapStart(len(v))
  8456. if e.h.Canonical {
  8457. v2 := make([]uint64, len(v))
  8458. var i int
  8459. for k, _ := range v {
  8460. v2[i] = uint64(k)
  8461. i++
  8462. }
  8463. sort.Sort(uintSlice(v2))
  8464. for _, k2 := range v2 {
  8465. if esep {
  8466. ee.WriteMapElemKey()
  8467. }
  8468. e.encode(uintptr(k2))
  8469. if esep {
  8470. ee.WriteMapElemValue()
  8471. }
  8472. ee.EncodeUint(uint64(v[uintptr(k2)]))
  8473. }
  8474. } else {
  8475. for k2, v2 := range v {
  8476. if esep {
  8477. ee.WriteMapElemKey()
  8478. }
  8479. e.encode(k2)
  8480. if esep {
  8481. ee.WriteMapElemValue()
  8482. }
  8483. ee.EncodeUint(uint64(v2))
  8484. }
  8485. }
  8486. ee.WriteMapEnd()
  8487. }
  8488. func (e *Encoder) fastpathEncMapUintptrUint8R(f *codecFnInfo, rv reflect.Value) {
  8489. fastpathTV.EncMapUintptrUint8V(rv2i(rv).(map[uintptr]uint8), e)
  8490. }
  8491. func (_ fastpathT) EncMapUintptrUint8V(v map[uintptr]uint8, e *Encoder) {
  8492. if v == nil {
  8493. e.e.EncodeNil()
  8494. return
  8495. }
  8496. ee, esep := e.e, e.hh.hasElemSeparators()
  8497. ee.WriteMapStart(len(v))
  8498. if e.h.Canonical {
  8499. v2 := make([]uint64, len(v))
  8500. var i int
  8501. for k, _ := range v {
  8502. v2[i] = uint64(k)
  8503. i++
  8504. }
  8505. sort.Sort(uintSlice(v2))
  8506. for _, k2 := range v2 {
  8507. if esep {
  8508. ee.WriteMapElemKey()
  8509. }
  8510. e.encode(uintptr(k2))
  8511. if esep {
  8512. ee.WriteMapElemValue()
  8513. }
  8514. ee.EncodeUint(uint64(v[uintptr(k2)]))
  8515. }
  8516. } else {
  8517. for k2, v2 := range v {
  8518. if esep {
  8519. ee.WriteMapElemKey()
  8520. }
  8521. e.encode(k2)
  8522. if esep {
  8523. ee.WriteMapElemValue()
  8524. }
  8525. ee.EncodeUint(uint64(v2))
  8526. }
  8527. }
  8528. ee.WriteMapEnd()
  8529. }
  8530. func (e *Encoder) fastpathEncMapUintptrUint16R(f *codecFnInfo, rv reflect.Value) {
  8531. fastpathTV.EncMapUintptrUint16V(rv2i(rv).(map[uintptr]uint16), e)
  8532. }
  8533. func (_ fastpathT) EncMapUintptrUint16V(v map[uintptr]uint16, e *Encoder) {
  8534. if v == nil {
  8535. e.e.EncodeNil()
  8536. return
  8537. }
  8538. ee, esep := e.e, e.hh.hasElemSeparators()
  8539. ee.WriteMapStart(len(v))
  8540. if e.h.Canonical {
  8541. v2 := make([]uint64, len(v))
  8542. var i int
  8543. for k, _ := range v {
  8544. v2[i] = uint64(k)
  8545. i++
  8546. }
  8547. sort.Sort(uintSlice(v2))
  8548. for _, k2 := range v2 {
  8549. if esep {
  8550. ee.WriteMapElemKey()
  8551. }
  8552. e.encode(uintptr(k2))
  8553. if esep {
  8554. ee.WriteMapElemValue()
  8555. }
  8556. ee.EncodeUint(uint64(v[uintptr(k2)]))
  8557. }
  8558. } else {
  8559. for k2, v2 := range v {
  8560. if esep {
  8561. ee.WriteMapElemKey()
  8562. }
  8563. e.encode(k2)
  8564. if esep {
  8565. ee.WriteMapElemValue()
  8566. }
  8567. ee.EncodeUint(uint64(v2))
  8568. }
  8569. }
  8570. ee.WriteMapEnd()
  8571. }
  8572. func (e *Encoder) fastpathEncMapUintptrUint32R(f *codecFnInfo, rv reflect.Value) {
  8573. fastpathTV.EncMapUintptrUint32V(rv2i(rv).(map[uintptr]uint32), e)
  8574. }
  8575. func (_ fastpathT) EncMapUintptrUint32V(v map[uintptr]uint32, e *Encoder) {
  8576. if v == nil {
  8577. e.e.EncodeNil()
  8578. return
  8579. }
  8580. ee, esep := e.e, e.hh.hasElemSeparators()
  8581. ee.WriteMapStart(len(v))
  8582. if e.h.Canonical {
  8583. v2 := make([]uint64, len(v))
  8584. var i int
  8585. for k, _ := range v {
  8586. v2[i] = uint64(k)
  8587. i++
  8588. }
  8589. sort.Sort(uintSlice(v2))
  8590. for _, k2 := range v2 {
  8591. if esep {
  8592. ee.WriteMapElemKey()
  8593. }
  8594. e.encode(uintptr(k2))
  8595. if esep {
  8596. ee.WriteMapElemValue()
  8597. }
  8598. ee.EncodeUint(uint64(v[uintptr(k2)]))
  8599. }
  8600. } else {
  8601. for k2, v2 := range v {
  8602. if esep {
  8603. ee.WriteMapElemKey()
  8604. }
  8605. e.encode(k2)
  8606. if esep {
  8607. ee.WriteMapElemValue()
  8608. }
  8609. ee.EncodeUint(uint64(v2))
  8610. }
  8611. }
  8612. ee.WriteMapEnd()
  8613. }
  8614. func (e *Encoder) fastpathEncMapUintptrUint64R(f *codecFnInfo, rv reflect.Value) {
  8615. fastpathTV.EncMapUintptrUint64V(rv2i(rv).(map[uintptr]uint64), e)
  8616. }
  8617. func (_ fastpathT) EncMapUintptrUint64V(v map[uintptr]uint64, e *Encoder) {
  8618. if v == nil {
  8619. e.e.EncodeNil()
  8620. return
  8621. }
  8622. ee, esep := e.e, e.hh.hasElemSeparators()
  8623. ee.WriteMapStart(len(v))
  8624. if e.h.Canonical {
  8625. v2 := make([]uint64, len(v))
  8626. var i int
  8627. for k, _ := range v {
  8628. v2[i] = uint64(k)
  8629. i++
  8630. }
  8631. sort.Sort(uintSlice(v2))
  8632. for _, k2 := range v2 {
  8633. if esep {
  8634. ee.WriteMapElemKey()
  8635. }
  8636. e.encode(uintptr(k2))
  8637. if esep {
  8638. ee.WriteMapElemValue()
  8639. }
  8640. ee.EncodeUint(uint64(v[uintptr(k2)]))
  8641. }
  8642. } else {
  8643. for k2, v2 := range v {
  8644. if esep {
  8645. ee.WriteMapElemKey()
  8646. }
  8647. e.encode(k2)
  8648. if esep {
  8649. ee.WriteMapElemValue()
  8650. }
  8651. ee.EncodeUint(uint64(v2))
  8652. }
  8653. }
  8654. ee.WriteMapEnd()
  8655. }
  8656. func (e *Encoder) fastpathEncMapUintptrUintptrR(f *codecFnInfo, rv reflect.Value) {
  8657. fastpathTV.EncMapUintptrUintptrV(rv2i(rv).(map[uintptr]uintptr), e)
  8658. }
  8659. func (_ fastpathT) EncMapUintptrUintptrV(v map[uintptr]uintptr, e *Encoder) {
  8660. if v == nil {
  8661. e.e.EncodeNil()
  8662. return
  8663. }
  8664. ee, esep := e.e, e.hh.hasElemSeparators()
  8665. ee.WriteMapStart(len(v))
  8666. if e.h.Canonical {
  8667. v2 := make([]uint64, len(v))
  8668. var i int
  8669. for k, _ := range v {
  8670. v2[i] = uint64(k)
  8671. i++
  8672. }
  8673. sort.Sort(uintSlice(v2))
  8674. for _, k2 := range v2 {
  8675. if esep {
  8676. ee.WriteMapElemKey()
  8677. }
  8678. e.encode(uintptr(k2))
  8679. if esep {
  8680. ee.WriteMapElemValue()
  8681. }
  8682. e.encode(v[uintptr(k2)])
  8683. }
  8684. } else {
  8685. for k2, v2 := range v {
  8686. if esep {
  8687. ee.WriteMapElemKey()
  8688. }
  8689. e.encode(k2)
  8690. if esep {
  8691. ee.WriteMapElemValue()
  8692. }
  8693. e.encode(v2)
  8694. }
  8695. }
  8696. ee.WriteMapEnd()
  8697. }
  8698. func (e *Encoder) fastpathEncMapUintptrIntR(f *codecFnInfo, rv reflect.Value) {
  8699. fastpathTV.EncMapUintptrIntV(rv2i(rv).(map[uintptr]int), e)
  8700. }
  8701. func (_ fastpathT) EncMapUintptrIntV(v map[uintptr]int, e *Encoder) {
  8702. if v == nil {
  8703. e.e.EncodeNil()
  8704. return
  8705. }
  8706. ee, esep := e.e, e.hh.hasElemSeparators()
  8707. ee.WriteMapStart(len(v))
  8708. if e.h.Canonical {
  8709. v2 := make([]uint64, len(v))
  8710. var i int
  8711. for k, _ := range v {
  8712. v2[i] = uint64(k)
  8713. i++
  8714. }
  8715. sort.Sort(uintSlice(v2))
  8716. for _, k2 := range v2 {
  8717. if esep {
  8718. ee.WriteMapElemKey()
  8719. }
  8720. e.encode(uintptr(k2))
  8721. if esep {
  8722. ee.WriteMapElemValue()
  8723. }
  8724. ee.EncodeInt(int64(v[uintptr(k2)]))
  8725. }
  8726. } else {
  8727. for k2, v2 := range v {
  8728. if esep {
  8729. ee.WriteMapElemKey()
  8730. }
  8731. e.encode(k2)
  8732. if esep {
  8733. ee.WriteMapElemValue()
  8734. }
  8735. ee.EncodeInt(int64(v2))
  8736. }
  8737. }
  8738. ee.WriteMapEnd()
  8739. }
  8740. func (e *Encoder) fastpathEncMapUintptrInt8R(f *codecFnInfo, rv reflect.Value) {
  8741. fastpathTV.EncMapUintptrInt8V(rv2i(rv).(map[uintptr]int8), e)
  8742. }
  8743. func (_ fastpathT) EncMapUintptrInt8V(v map[uintptr]int8, e *Encoder) {
  8744. if v == nil {
  8745. e.e.EncodeNil()
  8746. return
  8747. }
  8748. ee, esep := e.e, e.hh.hasElemSeparators()
  8749. ee.WriteMapStart(len(v))
  8750. if e.h.Canonical {
  8751. v2 := make([]uint64, len(v))
  8752. var i int
  8753. for k, _ := range v {
  8754. v2[i] = uint64(k)
  8755. i++
  8756. }
  8757. sort.Sort(uintSlice(v2))
  8758. for _, k2 := range v2 {
  8759. if esep {
  8760. ee.WriteMapElemKey()
  8761. }
  8762. e.encode(uintptr(k2))
  8763. if esep {
  8764. ee.WriteMapElemValue()
  8765. }
  8766. ee.EncodeInt(int64(v[uintptr(k2)]))
  8767. }
  8768. } else {
  8769. for k2, v2 := range v {
  8770. if esep {
  8771. ee.WriteMapElemKey()
  8772. }
  8773. e.encode(k2)
  8774. if esep {
  8775. ee.WriteMapElemValue()
  8776. }
  8777. ee.EncodeInt(int64(v2))
  8778. }
  8779. }
  8780. ee.WriteMapEnd()
  8781. }
  8782. func (e *Encoder) fastpathEncMapUintptrInt16R(f *codecFnInfo, rv reflect.Value) {
  8783. fastpathTV.EncMapUintptrInt16V(rv2i(rv).(map[uintptr]int16), e)
  8784. }
  8785. func (_ fastpathT) EncMapUintptrInt16V(v map[uintptr]int16, e *Encoder) {
  8786. if v == nil {
  8787. e.e.EncodeNil()
  8788. return
  8789. }
  8790. ee, esep := e.e, e.hh.hasElemSeparators()
  8791. ee.WriteMapStart(len(v))
  8792. if e.h.Canonical {
  8793. v2 := make([]uint64, len(v))
  8794. var i int
  8795. for k, _ := range v {
  8796. v2[i] = uint64(k)
  8797. i++
  8798. }
  8799. sort.Sort(uintSlice(v2))
  8800. for _, k2 := range v2 {
  8801. if esep {
  8802. ee.WriteMapElemKey()
  8803. }
  8804. e.encode(uintptr(k2))
  8805. if esep {
  8806. ee.WriteMapElemValue()
  8807. }
  8808. ee.EncodeInt(int64(v[uintptr(k2)]))
  8809. }
  8810. } else {
  8811. for k2, v2 := range v {
  8812. if esep {
  8813. ee.WriteMapElemKey()
  8814. }
  8815. e.encode(k2)
  8816. if esep {
  8817. ee.WriteMapElemValue()
  8818. }
  8819. ee.EncodeInt(int64(v2))
  8820. }
  8821. }
  8822. ee.WriteMapEnd()
  8823. }
  8824. func (e *Encoder) fastpathEncMapUintptrInt32R(f *codecFnInfo, rv reflect.Value) {
  8825. fastpathTV.EncMapUintptrInt32V(rv2i(rv).(map[uintptr]int32), e)
  8826. }
  8827. func (_ fastpathT) EncMapUintptrInt32V(v map[uintptr]int32, e *Encoder) {
  8828. if v == nil {
  8829. e.e.EncodeNil()
  8830. return
  8831. }
  8832. ee, esep := e.e, e.hh.hasElemSeparators()
  8833. ee.WriteMapStart(len(v))
  8834. if e.h.Canonical {
  8835. v2 := make([]uint64, len(v))
  8836. var i int
  8837. for k, _ := range v {
  8838. v2[i] = uint64(k)
  8839. i++
  8840. }
  8841. sort.Sort(uintSlice(v2))
  8842. for _, k2 := range v2 {
  8843. if esep {
  8844. ee.WriteMapElemKey()
  8845. }
  8846. e.encode(uintptr(k2))
  8847. if esep {
  8848. ee.WriteMapElemValue()
  8849. }
  8850. ee.EncodeInt(int64(v[uintptr(k2)]))
  8851. }
  8852. } else {
  8853. for k2, v2 := range v {
  8854. if esep {
  8855. ee.WriteMapElemKey()
  8856. }
  8857. e.encode(k2)
  8858. if esep {
  8859. ee.WriteMapElemValue()
  8860. }
  8861. ee.EncodeInt(int64(v2))
  8862. }
  8863. }
  8864. ee.WriteMapEnd()
  8865. }
  8866. func (e *Encoder) fastpathEncMapUintptrInt64R(f *codecFnInfo, rv reflect.Value) {
  8867. fastpathTV.EncMapUintptrInt64V(rv2i(rv).(map[uintptr]int64), e)
  8868. }
  8869. func (_ fastpathT) EncMapUintptrInt64V(v map[uintptr]int64, e *Encoder) {
  8870. if v == nil {
  8871. e.e.EncodeNil()
  8872. return
  8873. }
  8874. ee, esep := e.e, e.hh.hasElemSeparators()
  8875. ee.WriteMapStart(len(v))
  8876. if e.h.Canonical {
  8877. v2 := make([]uint64, len(v))
  8878. var i int
  8879. for k, _ := range v {
  8880. v2[i] = uint64(k)
  8881. i++
  8882. }
  8883. sort.Sort(uintSlice(v2))
  8884. for _, k2 := range v2 {
  8885. if esep {
  8886. ee.WriteMapElemKey()
  8887. }
  8888. e.encode(uintptr(k2))
  8889. if esep {
  8890. ee.WriteMapElemValue()
  8891. }
  8892. ee.EncodeInt(int64(v[uintptr(k2)]))
  8893. }
  8894. } else {
  8895. for k2, v2 := range v {
  8896. if esep {
  8897. ee.WriteMapElemKey()
  8898. }
  8899. e.encode(k2)
  8900. if esep {
  8901. ee.WriteMapElemValue()
  8902. }
  8903. ee.EncodeInt(int64(v2))
  8904. }
  8905. }
  8906. ee.WriteMapEnd()
  8907. }
  8908. func (e *Encoder) fastpathEncMapUintptrFloat32R(f *codecFnInfo, rv reflect.Value) {
  8909. fastpathTV.EncMapUintptrFloat32V(rv2i(rv).(map[uintptr]float32), e)
  8910. }
  8911. func (_ fastpathT) EncMapUintptrFloat32V(v map[uintptr]float32, e *Encoder) {
  8912. if v == nil {
  8913. e.e.EncodeNil()
  8914. return
  8915. }
  8916. ee, esep := e.e, e.hh.hasElemSeparators()
  8917. ee.WriteMapStart(len(v))
  8918. if e.h.Canonical {
  8919. v2 := make([]uint64, len(v))
  8920. var i int
  8921. for k, _ := range v {
  8922. v2[i] = uint64(k)
  8923. i++
  8924. }
  8925. sort.Sort(uintSlice(v2))
  8926. for _, k2 := range v2 {
  8927. if esep {
  8928. ee.WriteMapElemKey()
  8929. }
  8930. e.encode(uintptr(k2))
  8931. if esep {
  8932. ee.WriteMapElemValue()
  8933. }
  8934. ee.EncodeFloat32(v[uintptr(k2)])
  8935. }
  8936. } else {
  8937. for k2, v2 := range v {
  8938. if esep {
  8939. ee.WriteMapElemKey()
  8940. }
  8941. e.encode(k2)
  8942. if esep {
  8943. ee.WriteMapElemValue()
  8944. }
  8945. ee.EncodeFloat32(v2)
  8946. }
  8947. }
  8948. ee.WriteMapEnd()
  8949. }
  8950. func (e *Encoder) fastpathEncMapUintptrFloat64R(f *codecFnInfo, rv reflect.Value) {
  8951. fastpathTV.EncMapUintptrFloat64V(rv2i(rv).(map[uintptr]float64), e)
  8952. }
  8953. func (_ fastpathT) EncMapUintptrFloat64V(v map[uintptr]float64, e *Encoder) {
  8954. if v == nil {
  8955. e.e.EncodeNil()
  8956. return
  8957. }
  8958. ee, esep := e.e, e.hh.hasElemSeparators()
  8959. ee.WriteMapStart(len(v))
  8960. if e.h.Canonical {
  8961. v2 := make([]uint64, len(v))
  8962. var i int
  8963. for k, _ := range v {
  8964. v2[i] = uint64(k)
  8965. i++
  8966. }
  8967. sort.Sort(uintSlice(v2))
  8968. for _, k2 := range v2 {
  8969. if esep {
  8970. ee.WriteMapElemKey()
  8971. }
  8972. e.encode(uintptr(k2))
  8973. if esep {
  8974. ee.WriteMapElemValue()
  8975. }
  8976. ee.EncodeFloat64(v[uintptr(k2)])
  8977. }
  8978. } else {
  8979. for k2, v2 := range v {
  8980. if esep {
  8981. ee.WriteMapElemKey()
  8982. }
  8983. e.encode(k2)
  8984. if esep {
  8985. ee.WriteMapElemValue()
  8986. }
  8987. ee.EncodeFloat64(v2)
  8988. }
  8989. }
  8990. ee.WriteMapEnd()
  8991. }
  8992. func (e *Encoder) fastpathEncMapUintptrBoolR(f *codecFnInfo, rv reflect.Value) {
  8993. fastpathTV.EncMapUintptrBoolV(rv2i(rv).(map[uintptr]bool), e)
  8994. }
  8995. func (_ fastpathT) EncMapUintptrBoolV(v map[uintptr]bool, e *Encoder) {
  8996. if v == nil {
  8997. e.e.EncodeNil()
  8998. return
  8999. }
  9000. ee, esep := e.e, e.hh.hasElemSeparators()
  9001. ee.WriteMapStart(len(v))
  9002. if e.h.Canonical {
  9003. v2 := make([]uint64, len(v))
  9004. var i int
  9005. for k, _ := range v {
  9006. v2[i] = uint64(k)
  9007. i++
  9008. }
  9009. sort.Sort(uintSlice(v2))
  9010. for _, k2 := range v2 {
  9011. if esep {
  9012. ee.WriteMapElemKey()
  9013. }
  9014. e.encode(uintptr(k2))
  9015. if esep {
  9016. ee.WriteMapElemValue()
  9017. }
  9018. ee.EncodeBool(v[uintptr(k2)])
  9019. }
  9020. } else {
  9021. for k2, v2 := range v {
  9022. if esep {
  9023. ee.WriteMapElemKey()
  9024. }
  9025. e.encode(k2)
  9026. if esep {
  9027. ee.WriteMapElemValue()
  9028. }
  9029. ee.EncodeBool(v2)
  9030. }
  9031. }
  9032. ee.WriteMapEnd()
  9033. }
  9034. func (e *Encoder) fastpathEncMapIntIntfR(f *codecFnInfo, rv reflect.Value) {
  9035. fastpathTV.EncMapIntIntfV(rv2i(rv).(map[int]interface{}), e)
  9036. }
  9037. func (_ fastpathT) EncMapIntIntfV(v map[int]interface{}, e *Encoder) {
  9038. if v == nil {
  9039. e.e.EncodeNil()
  9040. return
  9041. }
  9042. ee, esep := e.e, e.hh.hasElemSeparators()
  9043. ee.WriteMapStart(len(v))
  9044. if e.h.Canonical {
  9045. v2 := make([]int64, len(v))
  9046. var i int
  9047. for k, _ := range v {
  9048. v2[i] = int64(k)
  9049. i++
  9050. }
  9051. sort.Sort(intSlice(v2))
  9052. for _, k2 := range v2 {
  9053. if esep {
  9054. ee.WriteMapElemKey()
  9055. }
  9056. ee.EncodeInt(int64(int(k2)))
  9057. if esep {
  9058. ee.WriteMapElemValue()
  9059. }
  9060. e.encode(v[int(k2)])
  9061. }
  9062. } else {
  9063. for k2, v2 := range v {
  9064. if esep {
  9065. ee.WriteMapElemKey()
  9066. }
  9067. ee.EncodeInt(int64(k2))
  9068. if esep {
  9069. ee.WriteMapElemValue()
  9070. }
  9071. e.encode(v2)
  9072. }
  9073. }
  9074. ee.WriteMapEnd()
  9075. }
  9076. func (e *Encoder) fastpathEncMapIntStringR(f *codecFnInfo, rv reflect.Value) {
  9077. fastpathTV.EncMapIntStringV(rv2i(rv).(map[int]string), e)
  9078. }
  9079. func (_ fastpathT) EncMapIntStringV(v map[int]string, e *Encoder) {
  9080. if v == nil {
  9081. e.e.EncodeNil()
  9082. return
  9083. }
  9084. ee, esep := e.e, e.hh.hasElemSeparators()
  9085. ee.WriteMapStart(len(v))
  9086. if e.h.Canonical {
  9087. v2 := make([]int64, len(v))
  9088. var i int
  9089. for k, _ := range v {
  9090. v2[i] = int64(k)
  9091. i++
  9092. }
  9093. sort.Sort(intSlice(v2))
  9094. for _, k2 := range v2 {
  9095. if esep {
  9096. ee.WriteMapElemKey()
  9097. }
  9098. ee.EncodeInt(int64(int(k2)))
  9099. if esep {
  9100. ee.WriteMapElemValue()
  9101. }
  9102. ee.EncodeString(cUTF8, v[int(k2)])
  9103. }
  9104. } else {
  9105. for k2, v2 := range v {
  9106. if esep {
  9107. ee.WriteMapElemKey()
  9108. }
  9109. ee.EncodeInt(int64(k2))
  9110. if esep {
  9111. ee.WriteMapElemValue()
  9112. }
  9113. ee.EncodeString(cUTF8, v2)
  9114. }
  9115. }
  9116. ee.WriteMapEnd()
  9117. }
  9118. func (e *Encoder) fastpathEncMapIntUintR(f *codecFnInfo, rv reflect.Value) {
  9119. fastpathTV.EncMapIntUintV(rv2i(rv).(map[int]uint), e)
  9120. }
  9121. func (_ fastpathT) EncMapIntUintV(v map[int]uint, e *Encoder) {
  9122. if v == nil {
  9123. e.e.EncodeNil()
  9124. return
  9125. }
  9126. ee, esep := e.e, e.hh.hasElemSeparators()
  9127. ee.WriteMapStart(len(v))
  9128. if e.h.Canonical {
  9129. v2 := make([]int64, len(v))
  9130. var i int
  9131. for k, _ := range v {
  9132. v2[i] = int64(k)
  9133. i++
  9134. }
  9135. sort.Sort(intSlice(v2))
  9136. for _, k2 := range v2 {
  9137. if esep {
  9138. ee.WriteMapElemKey()
  9139. }
  9140. ee.EncodeInt(int64(int(k2)))
  9141. if esep {
  9142. ee.WriteMapElemValue()
  9143. }
  9144. ee.EncodeUint(uint64(v[int(k2)]))
  9145. }
  9146. } else {
  9147. for k2, v2 := range v {
  9148. if esep {
  9149. ee.WriteMapElemKey()
  9150. }
  9151. ee.EncodeInt(int64(k2))
  9152. if esep {
  9153. ee.WriteMapElemValue()
  9154. }
  9155. ee.EncodeUint(uint64(v2))
  9156. }
  9157. }
  9158. ee.WriteMapEnd()
  9159. }
  9160. func (e *Encoder) fastpathEncMapIntUint8R(f *codecFnInfo, rv reflect.Value) {
  9161. fastpathTV.EncMapIntUint8V(rv2i(rv).(map[int]uint8), e)
  9162. }
  9163. func (_ fastpathT) EncMapIntUint8V(v map[int]uint8, e *Encoder) {
  9164. if v == nil {
  9165. e.e.EncodeNil()
  9166. return
  9167. }
  9168. ee, esep := e.e, e.hh.hasElemSeparators()
  9169. ee.WriteMapStart(len(v))
  9170. if e.h.Canonical {
  9171. v2 := make([]int64, len(v))
  9172. var i int
  9173. for k, _ := range v {
  9174. v2[i] = int64(k)
  9175. i++
  9176. }
  9177. sort.Sort(intSlice(v2))
  9178. for _, k2 := range v2 {
  9179. if esep {
  9180. ee.WriteMapElemKey()
  9181. }
  9182. ee.EncodeInt(int64(int(k2)))
  9183. if esep {
  9184. ee.WriteMapElemValue()
  9185. }
  9186. ee.EncodeUint(uint64(v[int(k2)]))
  9187. }
  9188. } else {
  9189. for k2, v2 := range v {
  9190. if esep {
  9191. ee.WriteMapElemKey()
  9192. }
  9193. ee.EncodeInt(int64(k2))
  9194. if esep {
  9195. ee.WriteMapElemValue()
  9196. }
  9197. ee.EncodeUint(uint64(v2))
  9198. }
  9199. }
  9200. ee.WriteMapEnd()
  9201. }
  9202. func (e *Encoder) fastpathEncMapIntUint16R(f *codecFnInfo, rv reflect.Value) {
  9203. fastpathTV.EncMapIntUint16V(rv2i(rv).(map[int]uint16), e)
  9204. }
  9205. func (_ fastpathT) EncMapIntUint16V(v map[int]uint16, e *Encoder) {
  9206. if v == nil {
  9207. e.e.EncodeNil()
  9208. return
  9209. }
  9210. ee, esep := e.e, e.hh.hasElemSeparators()
  9211. ee.WriteMapStart(len(v))
  9212. if e.h.Canonical {
  9213. v2 := make([]int64, len(v))
  9214. var i int
  9215. for k, _ := range v {
  9216. v2[i] = int64(k)
  9217. i++
  9218. }
  9219. sort.Sort(intSlice(v2))
  9220. for _, k2 := range v2 {
  9221. if esep {
  9222. ee.WriteMapElemKey()
  9223. }
  9224. ee.EncodeInt(int64(int(k2)))
  9225. if esep {
  9226. ee.WriteMapElemValue()
  9227. }
  9228. ee.EncodeUint(uint64(v[int(k2)]))
  9229. }
  9230. } else {
  9231. for k2, v2 := range v {
  9232. if esep {
  9233. ee.WriteMapElemKey()
  9234. }
  9235. ee.EncodeInt(int64(k2))
  9236. if esep {
  9237. ee.WriteMapElemValue()
  9238. }
  9239. ee.EncodeUint(uint64(v2))
  9240. }
  9241. }
  9242. ee.WriteMapEnd()
  9243. }
  9244. func (e *Encoder) fastpathEncMapIntUint32R(f *codecFnInfo, rv reflect.Value) {
  9245. fastpathTV.EncMapIntUint32V(rv2i(rv).(map[int]uint32), e)
  9246. }
  9247. func (_ fastpathT) EncMapIntUint32V(v map[int]uint32, e *Encoder) {
  9248. if v == nil {
  9249. e.e.EncodeNil()
  9250. return
  9251. }
  9252. ee, esep := e.e, e.hh.hasElemSeparators()
  9253. ee.WriteMapStart(len(v))
  9254. if e.h.Canonical {
  9255. v2 := make([]int64, len(v))
  9256. var i int
  9257. for k, _ := range v {
  9258. v2[i] = int64(k)
  9259. i++
  9260. }
  9261. sort.Sort(intSlice(v2))
  9262. for _, k2 := range v2 {
  9263. if esep {
  9264. ee.WriteMapElemKey()
  9265. }
  9266. ee.EncodeInt(int64(int(k2)))
  9267. if esep {
  9268. ee.WriteMapElemValue()
  9269. }
  9270. ee.EncodeUint(uint64(v[int(k2)]))
  9271. }
  9272. } else {
  9273. for k2, v2 := range v {
  9274. if esep {
  9275. ee.WriteMapElemKey()
  9276. }
  9277. ee.EncodeInt(int64(k2))
  9278. if esep {
  9279. ee.WriteMapElemValue()
  9280. }
  9281. ee.EncodeUint(uint64(v2))
  9282. }
  9283. }
  9284. ee.WriteMapEnd()
  9285. }
  9286. func (e *Encoder) fastpathEncMapIntUint64R(f *codecFnInfo, rv reflect.Value) {
  9287. fastpathTV.EncMapIntUint64V(rv2i(rv).(map[int]uint64), e)
  9288. }
  9289. func (_ fastpathT) EncMapIntUint64V(v map[int]uint64, e *Encoder) {
  9290. if v == nil {
  9291. e.e.EncodeNil()
  9292. return
  9293. }
  9294. ee, esep := e.e, e.hh.hasElemSeparators()
  9295. ee.WriteMapStart(len(v))
  9296. if e.h.Canonical {
  9297. v2 := make([]int64, len(v))
  9298. var i int
  9299. for k, _ := range v {
  9300. v2[i] = int64(k)
  9301. i++
  9302. }
  9303. sort.Sort(intSlice(v2))
  9304. for _, k2 := range v2 {
  9305. if esep {
  9306. ee.WriteMapElemKey()
  9307. }
  9308. ee.EncodeInt(int64(int(k2)))
  9309. if esep {
  9310. ee.WriteMapElemValue()
  9311. }
  9312. ee.EncodeUint(uint64(v[int(k2)]))
  9313. }
  9314. } else {
  9315. for k2, v2 := range v {
  9316. if esep {
  9317. ee.WriteMapElemKey()
  9318. }
  9319. ee.EncodeInt(int64(k2))
  9320. if esep {
  9321. ee.WriteMapElemValue()
  9322. }
  9323. ee.EncodeUint(uint64(v2))
  9324. }
  9325. }
  9326. ee.WriteMapEnd()
  9327. }
  9328. func (e *Encoder) fastpathEncMapIntUintptrR(f *codecFnInfo, rv reflect.Value) {
  9329. fastpathTV.EncMapIntUintptrV(rv2i(rv).(map[int]uintptr), e)
  9330. }
  9331. func (_ fastpathT) EncMapIntUintptrV(v map[int]uintptr, e *Encoder) {
  9332. if v == nil {
  9333. e.e.EncodeNil()
  9334. return
  9335. }
  9336. ee, esep := e.e, e.hh.hasElemSeparators()
  9337. ee.WriteMapStart(len(v))
  9338. if e.h.Canonical {
  9339. v2 := make([]int64, len(v))
  9340. var i int
  9341. for k, _ := range v {
  9342. v2[i] = int64(k)
  9343. i++
  9344. }
  9345. sort.Sort(intSlice(v2))
  9346. for _, k2 := range v2 {
  9347. if esep {
  9348. ee.WriteMapElemKey()
  9349. }
  9350. ee.EncodeInt(int64(int(k2)))
  9351. if esep {
  9352. ee.WriteMapElemValue()
  9353. }
  9354. e.encode(v[int(k2)])
  9355. }
  9356. } else {
  9357. for k2, v2 := range v {
  9358. if esep {
  9359. ee.WriteMapElemKey()
  9360. }
  9361. ee.EncodeInt(int64(k2))
  9362. if esep {
  9363. ee.WriteMapElemValue()
  9364. }
  9365. e.encode(v2)
  9366. }
  9367. }
  9368. ee.WriteMapEnd()
  9369. }
  9370. func (e *Encoder) fastpathEncMapIntIntR(f *codecFnInfo, rv reflect.Value) {
  9371. fastpathTV.EncMapIntIntV(rv2i(rv).(map[int]int), e)
  9372. }
  9373. func (_ fastpathT) EncMapIntIntV(v map[int]int, e *Encoder) {
  9374. if v == nil {
  9375. e.e.EncodeNil()
  9376. return
  9377. }
  9378. ee, esep := e.e, e.hh.hasElemSeparators()
  9379. ee.WriteMapStart(len(v))
  9380. if e.h.Canonical {
  9381. v2 := make([]int64, len(v))
  9382. var i int
  9383. for k, _ := range v {
  9384. v2[i] = int64(k)
  9385. i++
  9386. }
  9387. sort.Sort(intSlice(v2))
  9388. for _, k2 := range v2 {
  9389. if esep {
  9390. ee.WriteMapElemKey()
  9391. }
  9392. ee.EncodeInt(int64(int(k2)))
  9393. if esep {
  9394. ee.WriteMapElemValue()
  9395. }
  9396. ee.EncodeInt(int64(v[int(k2)]))
  9397. }
  9398. } else {
  9399. for k2, v2 := range v {
  9400. if esep {
  9401. ee.WriteMapElemKey()
  9402. }
  9403. ee.EncodeInt(int64(k2))
  9404. if esep {
  9405. ee.WriteMapElemValue()
  9406. }
  9407. ee.EncodeInt(int64(v2))
  9408. }
  9409. }
  9410. ee.WriteMapEnd()
  9411. }
  9412. func (e *Encoder) fastpathEncMapIntInt8R(f *codecFnInfo, rv reflect.Value) {
  9413. fastpathTV.EncMapIntInt8V(rv2i(rv).(map[int]int8), e)
  9414. }
  9415. func (_ fastpathT) EncMapIntInt8V(v map[int]int8, e *Encoder) {
  9416. if v == nil {
  9417. e.e.EncodeNil()
  9418. return
  9419. }
  9420. ee, esep := e.e, e.hh.hasElemSeparators()
  9421. ee.WriteMapStart(len(v))
  9422. if e.h.Canonical {
  9423. v2 := make([]int64, len(v))
  9424. var i int
  9425. for k, _ := range v {
  9426. v2[i] = int64(k)
  9427. i++
  9428. }
  9429. sort.Sort(intSlice(v2))
  9430. for _, k2 := range v2 {
  9431. if esep {
  9432. ee.WriteMapElemKey()
  9433. }
  9434. ee.EncodeInt(int64(int(k2)))
  9435. if esep {
  9436. ee.WriteMapElemValue()
  9437. }
  9438. ee.EncodeInt(int64(v[int(k2)]))
  9439. }
  9440. } else {
  9441. for k2, v2 := range v {
  9442. if esep {
  9443. ee.WriteMapElemKey()
  9444. }
  9445. ee.EncodeInt(int64(k2))
  9446. if esep {
  9447. ee.WriteMapElemValue()
  9448. }
  9449. ee.EncodeInt(int64(v2))
  9450. }
  9451. }
  9452. ee.WriteMapEnd()
  9453. }
  9454. func (e *Encoder) fastpathEncMapIntInt16R(f *codecFnInfo, rv reflect.Value) {
  9455. fastpathTV.EncMapIntInt16V(rv2i(rv).(map[int]int16), e)
  9456. }
  9457. func (_ fastpathT) EncMapIntInt16V(v map[int]int16, e *Encoder) {
  9458. if v == nil {
  9459. e.e.EncodeNil()
  9460. return
  9461. }
  9462. ee, esep := e.e, e.hh.hasElemSeparators()
  9463. ee.WriteMapStart(len(v))
  9464. if e.h.Canonical {
  9465. v2 := make([]int64, len(v))
  9466. var i int
  9467. for k, _ := range v {
  9468. v2[i] = int64(k)
  9469. i++
  9470. }
  9471. sort.Sort(intSlice(v2))
  9472. for _, k2 := range v2 {
  9473. if esep {
  9474. ee.WriteMapElemKey()
  9475. }
  9476. ee.EncodeInt(int64(int(k2)))
  9477. if esep {
  9478. ee.WriteMapElemValue()
  9479. }
  9480. ee.EncodeInt(int64(v[int(k2)]))
  9481. }
  9482. } else {
  9483. for k2, v2 := range v {
  9484. if esep {
  9485. ee.WriteMapElemKey()
  9486. }
  9487. ee.EncodeInt(int64(k2))
  9488. if esep {
  9489. ee.WriteMapElemValue()
  9490. }
  9491. ee.EncodeInt(int64(v2))
  9492. }
  9493. }
  9494. ee.WriteMapEnd()
  9495. }
  9496. func (e *Encoder) fastpathEncMapIntInt32R(f *codecFnInfo, rv reflect.Value) {
  9497. fastpathTV.EncMapIntInt32V(rv2i(rv).(map[int]int32), e)
  9498. }
  9499. func (_ fastpathT) EncMapIntInt32V(v map[int]int32, e *Encoder) {
  9500. if v == nil {
  9501. e.e.EncodeNil()
  9502. return
  9503. }
  9504. ee, esep := e.e, e.hh.hasElemSeparators()
  9505. ee.WriteMapStart(len(v))
  9506. if e.h.Canonical {
  9507. v2 := make([]int64, len(v))
  9508. var i int
  9509. for k, _ := range v {
  9510. v2[i] = int64(k)
  9511. i++
  9512. }
  9513. sort.Sort(intSlice(v2))
  9514. for _, k2 := range v2 {
  9515. if esep {
  9516. ee.WriteMapElemKey()
  9517. }
  9518. ee.EncodeInt(int64(int(k2)))
  9519. if esep {
  9520. ee.WriteMapElemValue()
  9521. }
  9522. ee.EncodeInt(int64(v[int(k2)]))
  9523. }
  9524. } else {
  9525. for k2, v2 := range v {
  9526. if esep {
  9527. ee.WriteMapElemKey()
  9528. }
  9529. ee.EncodeInt(int64(k2))
  9530. if esep {
  9531. ee.WriteMapElemValue()
  9532. }
  9533. ee.EncodeInt(int64(v2))
  9534. }
  9535. }
  9536. ee.WriteMapEnd()
  9537. }
  9538. func (e *Encoder) fastpathEncMapIntInt64R(f *codecFnInfo, rv reflect.Value) {
  9539. fastpathTV.EncMapIntInt64V(rv2i(rv).(map[int]int64), e)
  9540. }
  9541. func (_ fastpathT) EncMapIntInt64V(v map[int]int64, e *Encoder) {
  9542. if v == nil {
  9543. e.e.EncodeNil()
  9544. return
  9545. }
  9546. ee, esep := e.e, e.hh.hasElemSeparators()
  9547. ee.WriteMapStart(len(v))
  9548. if e.h.Canonical {
  9549. v2 := make([]int64, len(v))
  9550. var i int
  9551. for k, _ := range v {
  9552. v2[i] = int64(k)
  9553. i++
  9554. }
  9555. sort.Sort(intSlice(v2))
  9556. for _, k2 := range v2 {
  9557. if esep {
  9558. ee.WriteMapElemKey()
  9559. }
  9560. ee.EncodeInt(int64(int(k2)))
  9561. if esep {
  9562. ee.WriteMapElemValue()
  9563. }
  9564. ee.EncodeInt(int64(v[int(k2)]))
  9565. }
  9566. } else {
  9567. for k2, v2 := range v {
  9568. if esep {
  9569. ee.WriteMapElemKey()
  9570. }
  9571. ee.EncodeInt(int64(k2))
  9572. if esep {
  9573. ee.WriteMapElemValue()
  9574. }
  9575. ee.EncodeInt(int64(v2))
  9576. }
  9577. }
  9578. ee.WriteMapEnd()
  9579. }
  9580. func (e *Encoder) fastpathEncMapIntFloat32R(f *codecFnInfo, rv reflect.Value) {
  9581. fastpathTV.EncMapIntFloat32V(rv2i(rv).(map[int]float32), e)
  9582. }
  9583. func (_ fastpathT) EncMapIntFloat32V(v map[int]float32, e *Encoder) {
  9584. if v == nil {
  9585. e.e.EncodeNil()
  9586. return
  9587. }
  9588. ee, esep := e.e, e.hh.hasElemSeparators()
  9589. ee.WriteMapStart(len(v))
  9590. if e.h.Canonical {
  9591. v2 := make([]int64, len(v))
  9592. var i int
  9593. for k, _ := range v {
  9594. v2[i] = int64(k)
  9595. i++
  9596. }
  9597. sort.Sort(intSlice(v2))
  9598. for _, k2 := range v2 {
  9599. if esep {
  9600. ee.WriteMapElemKey()
  9601. }
  9602. ee.EncodeInt(int64(int(k2)))
  9603. if esep {
  9604. ee.WriteMapElemValue()
  9605. }
  9606. ee.EncodeFloat32(v[int(k2)])
  9607. }
  9608. } else {
  9609. for k2, v2 := range v {
  9610. if esep {
  9611. ee.WriteMapElemKey()
  9612. }
  9613. ee.EncodeInt(int64(k2))
  9614. if esep {
  9615. ee.WriteMapElemValue()
  9616. }
  9617. ee.EncodeFloat32(v2)
  9618. }
  9619. }
  9620. ee.WriteMapEnd()
  9621. }
  9622. func (e *Encoder) fastpathEncMapIntFloat64R(f *codecFnInfo, rv reflect.Value) {
  9623. fastpathTV.EncMapIntFloat64V(rv2i(rv).(map[int]float64), e)
  9624. }
  9625. func (_ fastpathT) EncMapIntFloat64V(v map[int]float64, e *Encoder) {
  9626. if v == nil {
  9627. e.e.EncodeNil()
  9628. return
  9629. }
  9630. ee, esep := e.e, e.hh.hasElemSeparators()
  9631. ee.WriteMapStart(len(v))
  9632. if e.h.Canonical {
  9633. v2 := make([]int64, len(v))
  9634. var i int
  9635. for k, _ := range v {
  9636. v2[i] = int64(k)
  9637. i++
  9638. }
  9639. sort.Sort(intSlice(v2))
  9640. for _, k2 := range v2 {
  9641. if esep {
  9642. ee.WriteMapElemKey()
  9643. }
  9644. ee.EncodeInt(int64(int(k2)))
  9645. if esep {
  9646. ee.WriteMapElemValue()
  9647. }
  9648. ee.EncodeFloat64(v[int(k2)])
  9649. }
  9650. } else {
  9651. for k2, v2 := range v {
  9652. if esep {
  9653. ee.WriteMapElemKey()
  9654. }
  9655. ee.EncodeInt(int64(k2))
  9656. if esep {
  9657. ee.WriteMapElemValue()
  9658. }
  9659. ee.EncodeFloat64(v2)
  9660. }
  9661. }
  9662. ee.WriteMapEnd()
  9663. }
  9664. func (e *Encoder) fastpathEncMapIntBoolR(f *codecFnInfo, rv reflect.Value) {
  9665. fastpathTV.EncMapIntBoolV(rv2i(rv).(map[int]bool), e)
  9666. }
  9667. func (_ fastpathT) EncMapIntBoolV(v map[int]bool, e *Encoder) {
  9668. if v == nil {
  9669. e.e.EncodeNil()
  9670. return
  9671. }
  9672. ee, esep := e.e, e.hh.hasElemSeparators()
  9673. ee.WriteMapStart(len(v))
  9674. if e.h.Canonical {
  9675. v2 := make([]int64, len(v))
  9676. var i int
  9677. for k, _ := range v {
  9678. v2[i] = int64(k)
  9679. i++
  9680. }
  9681. sort.Sort(intSlice(v2))
  9682. for _, k2 := range v2 {
  9683. if esep {
  9684. ee.WriteMapElemKey()
  9685. }
  9686. ee.EncodeInt(int64(int(k2)))
  9687. if esep {
  9688. ee.WriteMapElemValue()
  9689. }
  9690. ee.EncodeBool(v[int(k2)])
  9691. }
  9692. } else {
  9693. for k2, v2 := range v {
  9694. if esep {
  9695. ee.WriteMapElemKey()
  9696. }
  9697. ee.EncodeInt(int64(k2))
  9698. if esep {
  9699. ee.WriteMapElemValue()
  9700. }
  9701. ee.EncodeBool(v2)
  9702. }
  9703. }
  9704. ee.WriteMapEnd()
  9705. }
  9706. func (e *Encoder) fastpathEncMapInt8IntfR(f *codecFnInfo, rv reflect.Value) {
  9707. fastpathTV.EncMapInt8IntfV(rv2i(rv).(map[int8]interface{}), e)
  9708. }
  9709. func (_ fastpathT) EncMapInt8IntfV(v map[int8]interface{}, e *Encoder) {
  9710. if v == nil {
  9711. e.e.EncodeNil()
  9712. return
  9713. }
  9714. ee, esep := e.e, e.hh.hasElemSeparators()
  9715. ee.WriteMapStart(len(v))
  9716. if e.h.Canonical {
  9717. v2 := make([]int64, len(v))
  9718. var i int
  9719. for k, _ := range v {
  9720. v2[i] = int64(k)
  9721. i++
  9722. }
  9723. sort.Sort(intSlice(v2))
  9724. for _, k2 := range v2 {
  9725. if esep {
  9726. ee.WriteMapElemKey()
  9727. }
  9728. ee.EncodeInt(int64(int8(k2)))
  9729. if esep {
  9730. ee.WriteMapElemValue()
  9731. }
  9732. e.encode(v[int8(k2)])
  9733. }
  9734. } else {
  9735. for k2, v2 := range v {
  9736. if esep {
  9737. ee.WriteMapElemKey()
  9738. }
  9739. ee.EncodeInt(int64(k2))
  9740. if esep {
  9741. ee.WriteMapElemValue()
  9742. }
  9743. e.encode(v2)
  9744. }
  9745. }
  9746. ee.WriteMapEnd()
  9747. }
  9748. func (e *Encoder) fastpathEncMapInt8StringR(f *codecFnInfo, rv reflect.Value) {
  9749. fastpathTV.EncMapInt8StringV(rv2i(rv).(map[int8]string), e)
  9750. }
  9751. func (_ fastpathT) EncMapInt8StringV(v map[int8]string, e *Encoder) {
  9752. if v == nil {
  9753. e.e.EncodeNil()
  9754. return
  9755. }
  9756. ee, esep := e.e, e.hh.hasElemSeparators()
  9757. ee.WriteMapStart(len(v))
  9758. if e.h.Canonical {
  9759. v2 := make([]int64, len(v))
  9760. var i int
  9761. for k, _ := range v {
  9762. v2[i] = int64(k)
  9763. i++
  9764. }
  9765. sort.Sort(intSlice(v2))
  9766. for _, k2 := range v2 {
  9767. if esep {
  9768. ee.WriteMapElemKey()
  9769. }
  9770. ee.EncodeInt(int64(int8(k2)))
  9771. if esep {
  9772. ee.WriteMapElemValue()
  9773. }
  9774. ee.EncodeString(cUTF8, v[int8(k2)])
  9775. }
  9776. } else {
  9777. for k2, v2 := range v {
  9778. if esep {
  9779. ee.WriteMapElemKey()
  9780. }
  9781. ee.EncodeInt(int64(k2))
  9782. if esep {
  9783. ee.WriteMapElemValue()
  9784. }
  9785. ee.EncodeString(cUTF8, v2)
  9786. }
  9787. }
  9788. ee.WriteMapEnd()
  9789. }
  9790. func (e *Encoder) fastpathEncMapInt8UintR(f *codecFnInfo, rv reflect.Value) {
  9791. fastpathTV.EncMapInt8UintV(rv2i(rv).(map[int8]uint), e)
  9792. }
  9793. func (_ fastpathT) EncMapInt8UintV(v map[int8]uint, e *Encoder) {
  9794. if v == nil {
  9795. e.e.EncodeNil()
  9796. return
  9797. }
  9798. ee, esep := e.e, e.hh.hasElemSeparators()
  9799. ee.WriteMapStart(len(v))
  9800. if e.h.Canonical {
  9801. v2 := make([]int64, len(v))
  9802. var i int
  9803. for k, _ := range v {
  9804. v2[i] = int64(k)
  9805. i++
  9806. }
  9807. sort.Sort(intSlice(v2))
  9808. for _, k2 := range v2 {
  9809. if esep {
  9810. ee.WriteMapElemKey()
  9811. }
  9812. ee.EncodeInt(int64(int8(k2)))
  9813. if esep {
  9814. ee.WriteMapElemValue()
  9815. }
  9816. ee.EncodeUint(uint64(v[int8(k2)]))
  9817. }
  9818. } else {
  9819. for k2, v2 := range v {
  9820. if esep {
  9821. ee.WriteMapElemKey()
  9822. }
  9823. ee.EncodeInt(int64(k2))
  9824. if esep {
  9825. ee.WriteMapElemValue()
  9826. }
  9827. ee.EncodeUint(uint64(v2))
  9828. }
  9829. }
  9830. ee.WriteMapEnd()
  9831. }
  9832. func (e *Encoder) fastpathEncMapInt8Uint8R(f *codecFnInfo, rv reflect.Value) {
  9833. fastpathTV.EncMapInt8Uint8V(rv2i(rv).(map[int8]uint8), e)
  9834. }
  9835. func (_ fastpathT) EncMapInt8Uint8V(v map[int8]uint8, e *Encoder) {
  9836. if v == nil {
  9837. e.e.EncodeNil()
  9838. return
  9839. }
  9840. ee, esep := e.e, e.hh.hasElemSeparators()
  9841. ee.WriteMapStart(len(v))
  9842. if e.h.Canonical {
  9843. v2 := make([]int64, len(v))
  9844. var i int
  9845. for k, _ := range v {
  9846. v2[i] = int64(k)
  9847. i++
  9848. }
  9849. sort.Sort(intSlice(v2))
  9850. for _, k2 := range v2 {
  9851. if esep {
  9852. ee.WriteMapElemKey()
  9853. }
  9854. ee.EncodeInt(int64(int8(k2)))
  9855. if esep {
  9856. ee.WriteMapElemValue()
  9857. }
  9858. ee.EncodeUint(uint64(v[int8(k2)]))
  9859. }
  9860. } else {
  9861. for k2, v2 := range v {
  9862. if esep {
  9863. ee.WriteMapElemKey()
  9864. }
  9865. ee.EncodeInt(int64(k2))
  9866. if esep {
  9867. ee.WriteMapElemValue()
  9868. }
  9869. ee.EncodeUint(uint64(v2))
  9870. }
  9871. }
  9872. ee.WriteMapEnd()
  9873. }
  9874. func (e *Encoder) fastpathEncMapInt8Uint16R(f *codecFnInfo, rv reflect.Value) {
  9875. fastpathTV.EncMapInt8Uint16V(rv2i(rv).(map[int8]uint16), e)
  9876. }
  9877. func (_ fastpathT) EncMapInt8Uint16V(v map[int8]uint16, e *Encoder) {
  9878. if v == nil {
  9879. e.e.EncodeNil()
  9880. return
  9881. }
  9882. ee, esep := e.e, e.hh.hasElemSeparators()
  9883. ee.WriteMapStart(len(v))
  9884. if e.h.Canonical {
  9885. v2 := make([]int64, len(v))
  9886. var i int
  9887. for k, _ := range v {
  9888. v2[i] = int64(k)
  9889. i++
  9890. }
  9891. sort.Sort(intSlice(v2))
  9892. for _, k2 := range v2 {
  9893. if esep {
  9894. ee.WriteMapElemKey()
  9895. }
  9896. ee.EncodeInt(int64(int8(k2)))
  9897. if esep {
  9898. ee.WriteMapElemValue()
  9899. }
  9900. ee.EncodeUint(uint64(v[int8(k2)]))
  9901. }
  9902. } else {
  9903. for k2, v2 := range v {
  9904. if esep {
  9905. ee.WriteMapElemKey()
  9906. }
  9907. ee.EncodeInt(int64(k2))
  9908. if esep {
  9909. ee.WriteMapElemValue()
  9910. }
  9911. ee.EncodeUint(uint64(v2))
  9912. }
  9913. }
  9914. ee.WriteMapEnd()
  9915. }
  9916. func (e *Encoder) fastpathEncMapInt8Uint32R(f *codecFnInfo, rv reflect.Value) {
  9917. fastpathTV.EncMapInt8Uint32V(rv2i(rv).(map[int8]uint32), e)
  9918. }
  9919. func (_ fastpathT) EncMapInt8Uint32V(v map[int8]uint32, e *Encoder) {
  9920. if v == nil {
  9921. e.e.EncodeNil()
  9922. return
  9923. }
  9924. ee, esep := e.e, e.hh.hasElemSeparators()
  9925. ee.WriteMapStart(len(v))
  9926. if e.h.Canonical {
  9927. v2 := make([]int64, len(v))
  9928. var i int
  9929. for k, _ := range v {
  9930. v2[i] = int64(k)
  9931. i++
  9932. }
  9933. sort.Sort(intSlice(v2))
  9934. for _, k2 := range v2 {
  9935. if esep {
  9936. ee.WriteMapElemKey()
  9937. }
  9938. ee.EncodeInt(int64(int8(k2)))
  9939. if esep {
  9940. ee.WriteMapElemValue()
  9941. }
  9942. ee.EncodeUint(uint64(v[int8(k2)]))
  9943. }
  9944. } else {
  9945. for k2, v2 := range v {
  9946. if esep {
  9947. ee.WriteMapElemKey()
  9948. }
  9949. ee.EncodeInt(int64(k2))
  9950. if esep {
  9951. ee.WriteMapElemValue()
  9952. }
  9953. ee.EncodeUint(uint64(v2))
  9954. }
  9955. }
  9956. ee.WriteMapEnd()
  9957. }
  9958. func (e *Encoder) fastpathEncMapInt8Uint64R(f *codecFnInfo, rv reflect.Value) {
  9959. fastpathTV.EncMapInt8Uint64V(rv2i(rv).(map[int8]uint64), e)
  9960. }
  9961. func (_ fastpathT) EncMapInt8Uint64V(v map[int8]uint64, e *Encoder) {
  9962. if v == nil {
  9963. e.e.EncodeNil()
  9964. return
  9965. }
  9966. ee, esep := e.e, e.hh.hasElemSeparators()
  9967. ee.WriteMapStart(len(v))
  9968. if e.h.Canonical {
  9969. v2 := make([]int64, len(v))
  9970. var i int
  9971. for k, _ := range v {
  9972. v2[i] = int64(k)
  9973. i++
  9974. }
  9975. sort.Sort(intSlice(v2))
  9976. for _, k2 := range v2 {
  9977. if esep {
  9978. ee.WriteMapElemKey()
  9979. }
  9980. ee.EncodeInt(int64(int8(k2)))
  9981. if esep {
  9982. ee.WriteMapElemValue()
  9983. }
  9984. ee.EncodeUint(uint64(v[int8(k2)]))
  9985. }
  9986. } else {
  9987. for k2, v2 := range v {
  9988. if esep {
  9989. ee.WriteMapElemKey()
  9990. }
  9991. ee.EncodeInt(int64(k2))
  9992. if esep {
  9993. ee.WriteMapElemValue()
  9994. }
  9995. ee.EncodeUint(uint64(v2))
  9996. }
  9997. }
  9998. ee.WriteMapEnd()
  9999. }
  10000. func (e *Encoder) fastpathEncMapInt8UintptrR(f *codecFnInfo, rv reflect.Value) {
  10001. fastpathTV.EncMapInt8UintptrV(rv2i(rv).(map[int8]uintptr), e)
  10002. }
  10003. func (_ fastpathT) EncMapInt8UintptrV(v map[int8]uintptr, e *Encoder) {
  10004. if v == nil {
  10005. e.e.EncodeNil()
  10006. return
  10007. }
  10008. ee, esep := e.e, e.hh.hasElemSeparators()
  10009. ee.WriteMapStart(len(v))
  10010. if e.h.Canonical {
  10011. v2 := make([]int64, len(v))
  10012. var i int
  10013. for k, _ := range v {
  10014. v2[i] = int64(k)
  10015. i++
  10016. }
  10017. sort.Sort(intSlice(v2))
  10018. for _, k2 := range v2 {
  10019. if esep {
  10020. ee.WriteMapElemKey()
  10021. }
  10022. ee.EncodeInt(int64(int8(k2)))
  10023. if esep {
  10024. ee.WriteMapElemValue()
  10025. }
  10026. e.encode(v[int8(k2)])
  10027. }
  10028. } else {
  10029. for k2, v2 := range v {
  10030. if esep {
  10031. ee.WriteMapElemKey()
  10032. }
  10033. ee.EncodeInt(int64(k2))
  10034. if esep {
  10035. ee.WriteMapElemValue()
  10036. }
  10037. e.encode(v2)
  10038. }
  10039. }
  10040. ee.WriteMapEnd()
  10041. }
  10042. func (e *Encoder) fastpathEncMapInt8IntR(f *codecFnInfo, rv reflect.Value) {
  10043. fastpathTV.EncMapInt8IntV(rv2i(rv).(map[int8]int), e)
  10044. }
  10045. func (_ fastpathT) EncMapInt8IntV(v map[int8]int, e *Encoder) {
  10046. if v == nil {
  10047. e.e.EncodeNil()
  10048. return
  10049. }
  10050. ee, esep := e.e, e.hh.hasElemSeparators()
  10051. ee.WriteMapStart(len(v))
  10052. if e.h.Canonical {
  10053. v2 := make([]int64, len(v))
  10054. var i int
  10055. for k, _ := range v {
  10056. v2[i] = int64(k)
  10057. i++
  10058. }
  10059. sort.Sort(intSlice(v2))
  10060. for _, k2 := range v2 {
  10061. if esep {
  10062. ee.WriteMapElemKey()
  10063. }
  10064. ee.EncodeInt(int64(int8(k2)))
  10065. if esep {
  10066. ee.WriteMapElemValue()
  10067. }
  10068. ee.EncodeInt(int64(v[int8(k2)]))
  10069. }
  10070. } else {
  10071. for k2, v2 := range v {
  10072. if esep {
  10073. ee.WriteMapElemKey()
  10074. }
  10075. ee.EncodeInt(int64(k2))
  10076. if esep {
  10077. ee.WriteMapElemValue()
  10078. }
  10079. ee.EncodeInt(int64(v2))
  10080. }
  10081. }
  10082. ee.WriteMapEnd()
  10083. }
  10084. func (e *Encoder) fastpathEncMapInt8Int8R(f *codecFnInfo, rv reflect.Value) {
  10085. fastpathTV.EncMapInt8Int8V(rv2i(rv).(map[int8]int8), e)
  10086. }
  10087. func (_ fastpathT) EncMapInt8Int8V(v map[int8]int8, e *Encoder) {
  10088. if v == nil {
  10089. e.e.EncodeNil()
  10090. return
  10091. }
  10092. ee, esep := e.e, e.hh.hasElemSeparators()
  10093. ee.WriteMapStart(len(v))
  10094. if e.h.Canonical {
  10095. v2 := make([]int64, len(v))
  10096. var i int
  10097. for k, _ := range v {
  10098. v2[i] = int64(k)
  10099. i++
  10100. }
  10101. sort.Sort(intSlice(v2))
  10102. for _, k2 := range v2 {
  10103. if esep {
  10104. ee.WriteMapElemKey()
  10105. }
  10106. ee.EncodeInt(int64(int8(k2)))
  10107. if esep {
  10108. ee.WriteMapElemValue()
  10109. }
  10110. ee.EncodeInt(int64(v[int8(k2)]))
  10111. }
  10112. } else {
  10113. for k2, v2 := range v {
  10114. if esep {
  10115. ee.WriteMapElemKey()
  10116. }
  10117. ee.EncodeInt(int64(k2))
  10118. if esep {
  10119. ee.WriteMapElemValue()
  10120. }
  10121. ee.EncodeInt(int64(v2))
  10122. }
  10123. }
  10124. ee.WriteMapEnd()
  10125. }
  10126. func (e *Encoder) fastpathEncMapInt8Int16R(f *codecFnInfo, rv reflect.Value) {
  10127. fastpathTV.EncMapInt8Int16V(rv2i(rv).(map[int8]int16), e)
  10128. }
  10129. func (_ fastpathT) EncMapInt8Int16V(v map[int8]int16, e *Encoder) {
  10130. if v == nil {
  10131. e.e.EncodeNil()
  10132. return
  10133. }
  10134. ee, esep := e.e, e.hh.hasElemSeparators()
  10135. ee.WriteMapStart(len(v))
  10136. if e.h.Canonical {
  10137. v2 := make([]int64, len(v))
  10138. var i int
  10139. for k, _ := range v {
  10140. v2[i] = int64(k)
  10141. i++
  10142. }
  10143. sort.Sort(intSlice(v2))
  10144. for _, k2 := range v2 {
  10145. if esep {
  10146. ee.WriteMapElemKey()
  10147. }
  10148. ee.EncodeInt(int64(int8(k2)))
  10149. if esep {
  10150. ee.WriteMapElemValue()
  10151. }
  10152. ee.EncodeInt(int64(v[int8(k2)]))
  10153. }
  10154. } else {
  10155. for k2, v2 := range v {
  10156. if esep {
  10157. ee.WriteMapElemKey()
  10158. }
  10159. ee.EncodeInt(int64(k2))
  10160. if esep {
  10161. ee.WriteMapElemValue()
  10162. }
  10163. ee.EncodeInt(int64(v2))
  10164. }
  10165. }
  10166. ee.WriteMapEnd()
  10167. }
  10168. func (e *Encoder) fastpathEncMapInt8Int32R(f *codecFnInfo, rv reflect.Value) {
  10169. fastpathTV.EncMapInt8Int32V(rv2i(rv).(map[int8]int32), e)
  10170. }
  10171. func (_ fastpathT) EncMapInt8Int32V(v map[int8]int32, e *Encoder) {
  10172. if v == nil {
  10173. e.e.EncodeNil()
  10174. return
  10175. }
  10176. ee, esep := e.e, e.hh.hasElemSeparators()
  10177. ee.WriteMapStart(len(v))
  10178. if e.h.Canonical {
  10179. v2 := make([]int64, len(v))
  10180. var i int
  10181. for k, _ := range v {
  10182. v2[i] = int64(k)
  10183. i++
  10184. }
  10185. sort.Sort(intSlice(v2))
  10186. for _, k2 := range v2 {
  10187. if esep {
  10188. ee.WriteMapElemKey()
  10189. }
  10190. ee.EncodeInt(int64(int8(k2)))
  10191. if esep {
  10192. ee.WriteMapElemValue()
  10193. }
  10194. ee.EncodeInt(int64(v[int8(k2)]))
  10195. }
  10196. } else {
  10197. for k2, v2 := range v {
  10198. if esep {
  10199. ee.WriteMapElemKey()
  10200. }
  10201. ee.EncodeInt(int64(k2))
  10202. if esep {
  10203. ee.WriteMapElemValue()
  10204. }
  10205. ee.EncodeInt(int64(v2))
  10206. }
  10207. }
  10208. ee.WriteMapEnd()
  10209. }
  10210. func (e *Encoder) fastpathEncMapInt8Int64R(f *codecFnInfo, rv reflect.Value) {
  10211. fastpathTV.EncMapInt8Int64V(rv2i(rv).(map[int8]int64), e)
  10212. }
  10213. func (_ fastpathT) EncMapInt8Int64V(v map[int8]int64, e *Encoder) {
  10214. if v == nil {
  10215. e.e.EncodeNil()
  10216. return
  10217. }
  10218. ee, esep := e.e, e.hh.hasElemSeparators()
  10219. ee.WriteMapStart(len(v))
  10220. if e.h.Canonical {
  10221. v2 := make([]int64, len(v))
  10222. var i int
  10223. for k, _ := range v {
  10224. v2[i] = int64(k)
  10225. i++
  10226. }
  10227. sort.Sort(intSlice(v2))
  10228. for _, k2 := range v2 {
  10229. if esep {
  10230. ee.WriteMapElemKey()
  10231. }
  10232. ee.EncodeInt(int64(int8(k2)))
  10233. if esep {
  10234. ee.WriteMapElemValue()
  10235. }
  10236. ee.EncodeInt(int64(v[int8(k2)]))
  10237. }
  10238. } else {
  10239. for k2, v2 := range v {
  10240. if esep {
  10241. ee.WriteMapElemKey()
  10242. }
  10243. ee.EncodeInt(int64(k2))
  10244. if esep {
  10245. ee.WriteMapElemValue()
  10246. }
  10247. ee.EncodeInt(int64(v2))
  10248. }
  10249. }
  10250. ee.WriteMapEnd()
  10251. }
  10252. func (e *Encoder) fastpathEncMapInt8Float32R(f *codecFnInfo, rv reflect.Value) {
  10253. fastpathTV.EncMapInt8Float32V(rv2i(rv).(map[int8]float32), e)
  10254. }
  10255. func (_ fastpathT) EncMapInt8Float32V(v map[int8]float32, e *Encoder) {
  10256. if v == nil {
  10257. e.e.EncodeNil()
  10258. return
  10259. }
  10260. ee, esep := e.e, e.hh.hasElemSeparators()
  10261. ee.WriteMapStart(len(v))
  10262. if e.h.Canonical {
  10263. v2 := make([]int64, len(v))
  10264. var i int
  10265. for k, _ := range v {
  10266. v2[i] = int64(k)
  10267. i++
  10268. }
  10269. sort.Sort(intSlice(v2))
  10270. for _, k2 := range v2 {
  10271. if esep {
  10272. ee.WriteMapElemKey()
  10273. }
  10274. ee.EncodeInt(int64(int8(k2)))
  10275. if esep {
  10276. ee.WriteMapElemValue()
  10277. }
  10278. ee.EncodeFloat32(v[int8(k2)])
  10279. }
  10280. } else {
  10281. for k2, v2 := range v {
  10282. if esep {
  10283. ee.WriteMapElemKey()
  10284. }
  10285. ee.EncodeInt(int64(k2))
  10286. if esep {
  10287. ee.WriteMapElemValue()
  10288. }
  10289. ee.EncodeFloat32(v2)
  10290. }
  10291. }
  10292. ee.WriteMapEnd()
  10293. }
  10294. func (e *Encoder) fastpathEncMapInt8Float64R(f *codecFnInfo, rv reflect.Value) {
  10295. fastpathTV.EncMapInt8Float64V(rv2i(rv).(map[int8]float64), e)
  10296. }
  10297. func (_ fastpathT) EncMapInt8Float64V(v map[int8]float64, e *Encoder) {
  10298. if v == nil {
  10299. e.e.EncodeNil()
  10300. return
  10301. }
  10302. ee, esep := e.e, e.hh.hasElemSeparators()
  10303. ee.WriteMapStart(len(v))
  10304. if e.h.Canonical {
  10305. v2 := make([]int64, len(v))
  10306. var i int
  10307. for k, _ := range v {
  10308. v2[i] = int64(k)
  10309. i++
  10310. }
  10311. sort.Sort(intSlice(v2))
  10312. for _, k2 := range v2 {
  10313. if esep {
  10314. ee.WriteMapElemKey()
  10315. }
  10316. ee.EncodeInt(int64(int8(k2)))
  10317. if esep {
  10318. ee.WriteMapElemValue()
  10319. }
  10320. ee.EncodeFloat64(v[int8(k2)])
  10321. }
  10322. } else {
  10323. for k2, v2 := range v {
  10324. if esep {
  10325. ee.WriteMapElemKey()
  10326. }
  10327. ee.EncodeInt(int64(k2))
  10328. if esep {
  10329. ee.WriteMapElemValue()
  10330. }
  10331. ee.EncodeFloat64(v2)
  10332. }
  10333. }
  10334. ee.WriteMapEnd()
  10335. }
  10336. func (e *Encoder) fastpathEncMapInt8BoolR(f *codecFnInfo, rv reflect.Value) {
  10337. fastpathTV.EncMapInt8BoolV(rv2i(rv).(map[int8]bool), e)
  10338. }
  10339. func (_ fastpathT) EncMapInt8BoolV(v map[int8]bool, e *Encoder) {
  10340. if v == nil {
  10341. e.e.EncodeNil()
  10342. return
  10343. }
  10344. ee, esep := e.e, e.hh.hasElemSeparators()
  10345. ee.WriteMapStart(len(v))
  10346. if e.h.Canonical {
  10347. v2 := make([]int64, len(v))
  10348. var i int
  10349. for k, _ := range v {
  10350. v2[i] = int64(k)
  10351. i++
  10352. }
  10353. sort.Sort(intSlice(v2))
  10354. for _, k2 := range v2 {
  10355. if esep {
  10356. ee.WriteMapElemKey()
  10357. }
  10358. ee.EncodeInt(int64(int8(k2)))
  10359. if esep {
  10360. ee.WriteMapElemValue()
  10361. }
  10362. ee.EncodeBool(v[int8(k2)])
  10363. }
  10364. } else {
  10365. for k2, v2 := range v {
  10366. if esep {
  10367. ee.WriteMapElemKey()
  10368. }
  10369. ee.EncodeInt(int64(k2))
  10370. if esep {
  10371. ee.WriteMapElemValue()
  10372. }
  10373. ee.EncodeBool(v2)
  10374. }
  10375. }
  10376. ee.WriteMapEnd()
  10377. }
  10378. func (e *Encoder) fastpathEncMapInt16IntfR(f *codecFnInfo, rv reflect.Value) {
  10379. fastpathTV.EncMapInt16IntfV(rv2i(rv).(map[int16]interface{}), e)
  10380. }
  10381. func (_ fastpathT) EncMapInt16IntfV(v map[int16]interface{}, e *Encoder) {
  10382. if v == nil {
  10383. e.e.EncodeNil()
  10384. return
  10385. }
  10386. ee, esep := e.e, e.hh.hasElemSeparators()
  10387. ee.WriteMapStart(len(v))
  10388. if e.h.Canonical {
  10389. v2 := make([]int64, len(v))
  10390. var i int
  10391. for k, _ := range v {
  10392. v2[i] = int64(k)
  10393. i++
  10394. }
  10395. sort.Sort(intSlice(v2))
  10396. for _, k2 := range v2 {
  10397. if esep {
  10398. ee.WriteMapElemKey()
  10399. }
  10400. ee.EncodeInt(int64(int16(k2)))
  10401. if esep {
  10402. ee.WriteMapElemValue()
  10403. }
  10404. e.encode(v[int16(k2)])
  10405. }
  10406. } else {
  10407. for k2, v2 := range v {
  10408. if esep {
  10409. ee.WriteMapElemKey()
  10410. }
  10411. ee.EncodeInt(int64(k2))
  10412. if esep {
  10413. ee.WriteMapElemValue()
  10414. }
  10415. e.encode(v2)
  10416. }
  10417. }
  10418. ee.WriteMapEnd()
  10419. }
  10420. func (e *Encoder) fastpathEncMapInt16StringR(f *codecFnInfo, rv reflect.Value) {
  10421. fastpathTV.EncMapInt16StringV(rv2i(rv).(map[int16]string), e)
  10422. }
  10423. func (_ fastpathT) EncMapInt16StringV(v map[int16]string, e *Encoder) {
  10424. if v == nil {
  10425. e.e.EncodeNil()
  10426. return
  10427. }
  10428. ee, esep := e.e, e.hh.hasElemSeparators()
  10429. ee.WriteMapStart(len(v))
  10430. if e.h.Canonical {
  10431. v2 := make([]int64, len(v))
  10432. var i int
  10433. for k, _ := range v {
  10434. v2[i] = int64(k)
  10435. i++
  10436. }
  10437. sort.Sort(intSlice(v2))
  10438. for _, k2 := range v2 {
  10439. if esep {
  10440. ee.WriteMapElemKey()
  10441. }
  10442. ee.EncodeInt(int64(int16(k2)))
  10443. if esep {
  10444. ee.WriteMapElemValue()
  10445. }
  10446. ee.EncodeString(cUTF8, v[int16(k2)])
  10447. }
  10448. } else {
  10449. for k2, v2 := range v {
  10450. if esep {
  10451. ee.WriteMapElemKey()
  10452. }
  10453. ee.EncodeInt(int64(k2))
  10454. if esep {
  10455. ee.WriteMapElemValue()
  10456. }
  10457. ee.EncodeString(cUTF8, v2)
  10458. }
  10459. }
  10460. ee.WriteMapEnd()
  10461. }
  10462. func (e *Encoder) fastpathEncMapInt16UintR(f *codecFnInfo, rv reflect.Value) {
  10463. fastpathTV.EncMapInt16UintV(rv2i(rv).(map[int16]uint), e)
  10464. }
  10465. func (_ fastpathT) EncMapInt16UintV(v map[int16]uint, e *Encoder) {
  10466. if v == nil {
  10467. e.e.EncodeNil()
  10468. return
  10469. }
  10470. ee, esep := e.e, e.hh.hasElemSeparators()
  10471. ee.WriteMapStart(len(v))
  10472. if e.h.Canonical {
  10473. v2 := make([]int64, len(v))
  10474. var i int
  10475. for k, _ := range v {
  10476. v2[i] = int64(k)
  10477. i++
  10478. }
  10479. sort.Sort(intSlice(v2))
  10480. for _, k2 := range v2 {
  10481. if esep {
  10482. ee.WriteMapElemKey()
  10483. }
  10484. ee.EncodeInt(int64(int16(k2)))
  10485. if esep {
  10486. ee.WriteMapElemValue()
  10487. }
  10488. ee.EncodeUint(uint64(v[int16(k2)]))
  10489. }
  10490. } else {
  10491. for k2, v2 := range v {
  10492. if esep {
  10493. ee.WriteMapElemKey()
  10494. }
  10495. ee.EncodeInt(int64(k2))
  10496. if esep {
  10497. ee.WriteMapElemValue()
  10498. }
  10499. ee.EncodeUint(uint64(v2))
  10500. }
  10501. }
  10502. ee.WriteMapEnd()
  10503. }
  10504. func (e *Encoder) fastpathEncMapInt16Uint8R(f *codecFnInfo, rv reflect.Value) {
  10505. fastpathTV.EncMapInt16Uint8V(rv2i(rv).(map[int16]uint8), e)
  10506. }
  10507. func (_ fastpathT) EncMapInt16Uint8V(v map[int16]uint8, e *Encoder) {
  10508. if v == nil {
  10509. e.e.EncodeNil()
  10510. return
  10511. }
  10512. ee, esep := e.e, e.hh.hasElemSeparators()
  10513. ee.WriteMapStart(len(v))
  10514. if e.h.Canonical {
  10515. v2 := make([]int64, len(v))
  10516. var i int
  10517. for k, _ := range v {
  10518. v2[i] = int64(k)
  10519. i++
  10520. }
  10521. sort.Sort(intSlice(v2))
  10522. for _, k2 := range v2 {
  10523. if esep {
  10524. ee.WriteMapElemKey()
  10525. }
  10526. ee.EncodeInt(int64(int16(k2)))
  10527. if esep {
  10528. ee.WriteMapElemValue()
  10529. }
  10530. ee.EncodeUint(uint64(v[int16(k2)]))
  10531. }
  10532. } else {
  10533. for k2, v2 := range v {
  10534. if esep {
  10535. ee.WriteMapElemKey()
  10536. }
  10537. ee.EncodeInt(int64(k2))
  10538. if esep {
  10539. ee.WriteMapElemValue()
  10540. }
  10541. ee.EncodeUint(uint64(v2))
  10542. }
  10543. }
  10544. ee.WriteMapEnd()
  10545. }
  10546. func (e *Encoder) fastpathEncMapInt16Uint16R(f *codecFnInfo, rv reflect.Value) {
  10547. fastpathTV.EncMapInt16Uint16V(rv2i(rv).(map[int16]uint16), e)
  10548. }
  10549. func (_ fastpathT) EncMapInt16Uint16V(v map[int16]uint16, e *Encoder) {
  10550. if v == nil {
  10551. e.e.EncodeNil()
  10552. return
  10553. }
  10554. ee, esep := e.e, e.hh.hasElemSeparators()
  10555. ee.WriteMapStart(len(v))
  10556. if e.h.Canonical {
  10557. v2 := make([]int64, len(v))
  10558. var i int
  10559. for k, _ := range v {
  10560. v2[i] = int64(k)
  10561. i++
  10562. }
  10563. sort.Sort(intSlice(v2))
  10564. for _, k2 := range v2 {
  10565. if esep {
  10566. ee.WriteMapElemKey()
  10567. }
  10568. ee.EncodeInt(int64(int16(k2)))
  10569. if esep {
  10570. ee.WriteMapElemValue()
  10571. }
  10572. ee.EncodeUint(uint64(v[int16(k2)]))
  10573. }
  10574. } else {
  10575. for k2, v2 := range v {
  10576. if esep {
  10577. ee.WriteMapElemKey()
  10578. }
  10579. ee.EncodeInt(int64(k2))
  10580. if esep {
  10581. ee.WriteMapElemValue()
  10582. }
  10583. ee.EncodeUint(uint64(v2))
  10584. }
  10585. }
  10586. ee.WriteMapEnd()
  10587. }
  10588. func (e *Encoder) fastpathEncMapInt16Uint32R(f *codecFnInfo, rv reflect.Value) {
  10589. fastpathTV.EncMapInt16Uint32V(rv2i(rv).(map[int16]uint32), e)
  10590. }
  10591. func (_ fastpathT) EncMapInt16Uint32V(v map[int16]uint32, e *Encoder) {
  10592. if v == nil {
  10593. e.e.EncodeNil()
  10594. return
  10595. }
  10596. ee, esep := e.e, e.hh.hasElemSeparators()
  10597. ee.WriteMapStart(len(v))
  10598. if e.h.Canonical {
  10599. v2 := make([]int64, len(v))
  10600. var i int
  10601. for k, _ := range v {
  10602. v2[i] = int64(k)
  10603. i++
  10604. }
  10605. sort.Sort(intSlice(v2))
  10606. for _, k2 := range v2 {
  10607. if esep {
  10608. ee.WriteMapElemKey()
  10609. }
  10610. ee.EncodeInt(int64(int16(k2)))
  10611. if esep {
  10612. ee.WriteMapElemValue()
  10613. }
  10614. ee.EncodeUint(uint64(v[int16(k2)]))
  10615. }
  10616. } else {
  10617. for k2, v2 := range v {
  10618. if esep {
  10619. ee.WriteMapElemKey()
  10620. }
  10621. ee.EncodeInt(int64(k2))
  10622. if esep {
  10623. ee.WriteMapElemValue()
  10624. }
  10625. ee.EncodeUint(uint64(v2))
  10626. }
  10627. }
  10628. ee.WriteMapEnd()
  10629. }
  10630. func (e *Encoder) fastpathEncMapInt16Uint64R(f *codecFnInfo, rv reflect.Value) {
  10631. fastpathTV.EncMapInt16Uint64V(rv2i(rv).(map[int16]uint64), e)
  10632. }
  10633. func (_ fastpathT) EncMapInt16Uint64V(v map[int16]uint64, e *Encoder) {
  10634. if v == nil {
  10635. e.e.EncodeNil()
  10636. return
  10637. }
  10638. ee, esep := e.e, e.hh.hasElemSeparators()
  10639. ee.WriteMapStart(len(v))
  10640. if e.h.Canonical {
  10641. v2 := make([]int64, len(v))
  10642. var i int
  10643. for k, _ := range v {
  10644. v2[i] = int64(k)
  10645. i++
  10646. }
  10647. sort.Sort(intSlice(v2))
  10648. for _, k2 := range v2 {
  10649. if esep {
  10650. ee.WriteMapElemKey()
  10651. }
  10652. ee.EncodeInt(int64(int16(k2)))
  10653. if esep {
  10654. ee.WriteMapElemValue()
  10655. }
  10656. ee.EncodeUint(uint64(v[int16(k2)]))
  10657. }
  10658. } else {
  10659. for k2, v2 := range v {
  10660. if esep {
  10661. ee.WriteMapElemKey()
  10662. }
  10663. ee.EncodeInt(int64(k2))
  10664. if esep {
  10665. ee.WriteMapElemValue()
  10666. }
  10667. ee.EncodeUint(uint64(v2))
  10668. }
  10669. }
  10670. ee.WriteMapEnd()
  10671. }
  10672. func (e *Encoder) fastpathEncMapInt16UintptrR(f *codecFnInfo, rv reflect.Value) {
  10673. fastpathTV.EncMapInt16UintptrV(rv2i(rv).(map[int16]uintptr), e)
  10674. }
  10675. func (_ fastpathT) EncMapInt16UintptrV(v map[int16]uintptr, e *Encoder) {
  10676. if v == nil {
  10677. e.e.EncodeNil()
  10678. return
  10679. }
  10680. ee, esep := e.e, e.hh.hasElemSeparators()
  10681. ee.WriteMapStart(len(v))
  10682. if e.h.Canonical {
  10683. v2 := make([]int64, len(v))
  10684. var i int
  10685. for k, _ := range v {
  10686. v2[i] = int64(k)
  10687. i++
  10688. }
  10689. sort.Sort(intSlice(v2))
  10690. for _, k2 := range v2 {
  10691. if esep {
  10692. ee.WriteMapElemKey()
  10693. }
  10694. ee.EncodeInt(int64(int16(k2)))
  10695. if esep {
  10696. ee.WriteMapElemValue()
  10697. }
  10698. e.encode(v[int16(k2)])
  10699. }
  10700. } else {
  10701. for k2, v2 := range v {
  10702. if esep {
  10703. ee.WriteMapElemKey()
  10704. }
  10705. ee.EncodeInt(int64(k2))
  10706. if esep {
  10707. ee.WriteMapElemValue()
  10708. }
  10709. e.encode(v2)
  10710. }
  10711. }
  10712. ee.WriteMapEnd()
  10713. }
  10714. func (e *Encoder) fastpathEncMapInt16IntR(f *codecFnInfo, rv reflect.Value) {
  10715. fastpathTV.EncMapInt16IntV(rv2i(rv).(map[int16]int), e)
  10716. }
  10717. func (_ fastpathT) EncMapInt16IntV(v map[int16]int, e *Encoder) {
  10718. if v == nil {
  10719. e.e.EncodeNil()
  10720. return
  10721. }
  10722. ee, esep := e.e, e.hh.hasElemSeparators()
  10723. ee.WriteMapStart(len(v))
  10724. if e.h.Canonical {
  10725. v2 := make([]int64, len(v))
  10726. var i int
  10727. for k, _ := range v {
  10728. v2[i] = int64(k)
  10729. i++
  10730. }
  10731. sort.Sort(intSlice(v2))
  10732. for _, k2 := range v2 {
  10733. if esep {
  10734. ee.WriteMapElemKey()
  10735. }
  10736. ee.EncodeInt(int64(int16(k2)))
  10737. if esep {
  10738. ee.WriteMapElemValue()
  10739. }
  10740. ee.EncodeInt(int64(v[int16(k2)]))
  10741. }
  10742. } else {
  10743. for k2, v2 := range v {
  10744. if esep {
  10745. ee.WriteMapElemKey()
  10746. }
  10747. ee.EncodeInt(int64(k2))
  10748. if esep {
  10749. ee.WriteMapElemValue()
  10750. }
  10751. ee.EncodeInt(int64(v2))
  10752. }
  10753. }
  10754. ee.WriteMapEnd()
  10755. }
  10756. func (e *Encoder) fastpathEncMapInt16Int8R(f *codecFnInfo, rv reflect.Value) {
  10757. fastpathTV.EncMapInt16Int8V(rv2i(rv).(map[int16]int8), e)
  10758. }
  10759. func (_ fastpathT) EncMapInt16Int8V(v map[int16]int8, e *Encoder) {
  10760. if v == nil {
  10761. e.e.EncodeNil()
  10762. return
  10763. }
  10764. ee, esep := e.e, e.hh.hasElemSeparators()
  10765. ee.WriteMapStart(len(v))
  10766. if e.h.Canonical {
  10767. v2 := make([]int64, len(v))
  10768. var i int
  10769. for k, _ := range v {
  10770. v2[i] = int64(k)
  10771. i++
  10772. }
  10773. sort.Sort(intSlice(v2))
  10774. for _, k2 := range v2 {
  10775. if esep {
  10776. ee.WriteMapElemKey()
  10777. }
  10778. ee.EncodeInt(int64(int16(k2)))
  10779. if esep {
  10780. ee.WriteMapElemValue()
  10781. }
  10782. ee.EncodeInt(int64(v[int16(k2)]))
  10783. }
  10784. } else {
  10785. for k2, v2 := range v {
  10786. if esep {
  10787. ee.WriteMapElemKey()
  10788. }
  10789. ee.EncodeInt(int64(k2))
  10790. if esep {
  10791. ee.WriteMapElemValue()
  10792. }
  10793. ee.EncodeInt(int64(v2))
  10794. }
  10795. }
  10796. ee.WriteMapEnd()
  10797. }
  10798. func (e *Encoder) fastpathEncMapInt16Int16R(f *codecFnInfo, rv reflect.Value) {
  10799. fastpathTV.EncMapInt16Int16V(rv2i(rv).(map[int16]int16), e)
  10800. }
  10801. func (_ fastpathT) EncMapInt16Int16V(v map[int16]int16, e *Encoder) {
  10802. if v == nil {
  10803. e.e.EncodeNil()
  10804. return
  10805. }
  10806. ee, esep := e.e, e.hh.hasElemSeparators()
  10807. ee.WriteMapStart(len(v))
  10808. if e.h.Canonical {
  10809. v2 := make([]int64, len(v))
  10810. var i int
  10811. for k, _ := range v {
  10812. v2[i] = int64(k)
  10813. i++
  10814. }
  10815. sort.Sort(intSlice(v2))
  10816. for _, k2 := range v2 {
  10817. if esep {
  10818. ee.WriteMapElemKey()
  10819. }
  10820. ee.EncodeInt(int64(int16(k2)))
  10821. if esep {
  10822. ee.WriteMapElemValue()
  10823. }
  10824. ee.EncodeInt(int64(v[int16(k2)]))
  10825. }
  10826. } else {
  10827. for k2, v2 := range v {
  10828. if esep {
  10829. ee.WriteMapElemKey()
  10830. }
  10831. ee.EncodeInt(int64(k2))
  10832. if esep {
  10833. ee.WriteMapElemValue()
  10834. }
  10835. ee.EncodeInt(int64(v2))
  10836. }
  10837. }
  10838. ee.WriteMapEnd()
  10839. }
  10840. func (e *Encoder) fastpathEncMapInt16Int32R(f *codecFnInfo, rv reflect.Value) {
  10841. fastpathTV.EncMapInt16Int32V(rv2i(rv).(map[int16]int32), e)
  10842. }
  10843. func (_ fastpathT) EncMapInt16Int32V(v map[int16]int32, e *Encoder) {
  10844. if v == nil {
  10845. e.e.EncodeNil()
  10846. return
  10847. }
  10848. ee, esep := e.e, e.hh.hasElemSeparators()
  10849. ee.WriteMapStart(len(v))
  10850. if e.h.Canonical {
  10851. v2 := make([]int64, len(v))
  10852. var i int
  10853. for k, _ := range v {
  10854. v2[i] = int64(k)
  10855. i++
  10856. }
  10857. sort.Sort(intSlice(v2))
  10858. for _, k2 := range v2 {
  10859. if esep {
  10860. ee.WriteMapElemKey()
  10861. }
  10862. ee.EncodeInt(int64(int16(k2)))
  10863. if esep {
  10864. ee.WriteMapElemValue()
  10865. }
  10866. ee.EncodeInt(int64(v[int16(k2)]))
  10867. }
  10868. } else {
  10869. for k2, v2 := range v {
  10870. if esep {
  10871. ee.WriteMapElemKey()
  10872. }
  10873. ee.EncodeInt(int64(k2))
  10874. if esep {
  10875. ee.WriteMapElemValue()
  10876. }
  10877. ee.EncodeInt(int64(v2))
  10878. }
  10879. }
  10880. ee.WriteMapEnd()
  10881. }
  10882. func (e *Encoder) fastpathEncMapInt16Int64R(f *codecFnInfo, rv reflect.Value) {
  10883. fastpathTV.EncMapInt16Int64V(rv2i(rv).(map[int16]int64), e)
  10884. }
  10885. func (_ fastpathT) EncMapInt16Int64V(v map[int16]int64, e *Encoder) {
  10886. if v == nil {
  10887. e.e.EncodeNil()
  10888. return
  10889. }
  10890. ee, esep := e.e, e.hh.hasElemSeparators()
  10891. ee.WriteMapStart(len(v))
  10892. if e.h.Canonical {
  10893. v2 := make([]int64, len(v))
  10894. var i int
  10895. for k, _ := range v {
  10896. v2[i] = int64(k)
  10897. i++
  10898. }
  10899. sort.Sort(intSlice(v2))
  10900. for _, k2 := range v2 {
  10901. if esep {
  10902. ee.WriteMapElemKey()
  10903. }
  10904. ee.EncodeInt(int64(int16(k2)))
  10905. if esep {
  10906. ee.WriteMapElemValue()
  10907. }
  10908. ee.EncodeInt(int64(v[int16(k2)]))
  10909. }
  10910. } else {
  10911. for k2, v2 := range v {
  10912. if esep {
  10913. ee.WriteMapElemKey()
  10914. }
  10915. ee.EncodeInt(int64(k2))
  10916. if esep {
  10917. ee.WriteMapElemValue()
  10918. }
  10919. ee.EncodeInt(int64(v2))
  10920. }
  10921. }
  10922. ee.WriteMapEnd()
  10923. }
  10924. func (e *Encoder) fastpathEncMapInt16Float32R(f *codecFnInfo, rv reflect.Value) {
  10925. fastpathTV.EncMapInt16Float32V(rv2i(rv).(map[int16]float32), e)
  10926. }
  10927. func (_ fastpathT) EncMapInt16Float32V(v map[int16]float32, e *Encoder) {
  10928. if v == nil {
  10929. e.e.EncodeNil()
  10930. return
  10931. }
  10932. ee, esep := e.e, e.hh.hasElemSeparators()
  10933. ee.WriteMapStart(len(v))
  10934. if e.h.Canonical {
  10935. v2 := make([]int64, len(v))
  10936. var i int
  10937. for k, _ := range v {
  10938. v2[i] = int64(k)
  10939. i++
  10940. }
  10941. sort.Sort(intSlice(v2))
  10942. for _, k2 := range v2 {
  10943. if esep {
  10944. ee.WriteMapElemKey()
  10945. }
  10946. ee.EncodeInt(int64(int16(k2)))
  10947. if esep {
  10948. ee.WriteMapElemValue()
  10949. }
  10950. ee.EncodeFloat32(v[int16(k2)])
  10951. }
  10952. } else {
  10953. for k2, v2 := range v {
  10954. if esep {
  10955. ee.WriteMapElemKey()
  10956. }
  10957. ee.EncodeInt(int64(k2))
  10958. if esep {
  10959. ee.WriteMapElemValue()
  10960. }
  10961. ee.EncodeFloat32(v2)
  10962. }
  10963. }
  10964. ee.WriteMapEnd()
  10965. }
  10966. func (e *Encoder) fastpathEncMapInt16Float64R(f *codecFnInfo, rv reflect.Value) {
  10967. fastpathTV.EncMapInt16Float64V(rv2i(rv).(map[int16]float64), e)
  10968. }
  10969. func (_ fastpathT) EncMapInt16Float64V(v map[int16]float64, e *Encoder) {
  10970. if v == nil {
  10971. e.e.EncodeNil()
  10972. return
  10973. }
  10974. ee, esep := e.e, e.hh.hasElemSeparators()
  10975. ee.WriteMapStart(len(v))
  10976. if e.h.Canonical {
  10977. v2 := make([]int64, len(v))
  10978. var i int
  10979. for k, _ := range v {
  10980. v2[i] = int64(k)
  10981. i++
  10982. }
  10983. sort.Sort(intSlice(v2))
  10984. for _, k2 := range v2 {
  10985. if esep {
  10986. ee.WriteMapElemKey()
  10987. }
  10988. ee.EncodeInt(int64(int16(k2)))
  10989. if esep {
  10990. ee.WriteMapElemValue()
  10991. }
  10992. ee.EncodeFloat64(v[int16(k2)])
  10993. }
  10994. } else {
  10995. for k2, v2 := range v {
  10996. if esep {
  10997. ee.WriteMapElemKey()
  10998. }
  10999. ee.EncodeInt(int64(k2))
  11000. if esep {
  11001. ee.WriteMapElemValue()
  11002. }
  11003. ee.EncodeFloat64(v2)
  11004. }
  11005. }
  11006. ee.WriteMapEnd()
  11007. }
  11008. func (e *Encoder) fastpathEncMapInt16BoolR(f *codecFnInfo, rv reflect.Value) {
  11009. fastpathTV.EncMapInt16BoolV(rv2i(rv).(map[int16]bool), e)
  11010. }
  11011. func (_ fastpathT) EncMapInt16BoolV(v map[int16]bool, e *Encoder) {
  11012. if v == nil {
  11013. e.e.EncodeNil()
  11014. return
  11015. }
  11016. ee, esep := e.e, e.hh.hasElemSeparators()
  11017. ee.WriteMapStart(len(v))
  11018. if e.h.Canonical {
  11019. v2 := make([]int64, len(v))
  11020. var i int
  11021. for k, _ := range v {
  11022. v2[i] = int64(k)
  11023. i++
  11024. }
  11025. sort.Sort(intSlice(v2))
  11026. for _, k2 := range v2 {
  11027. if esep {
  11028. ee.WriteMapElemKey()
  11029. }
  11030. ee.EncodeInt(int64(int16(k2)))
  11031. if esep {
  11032. ee.WriteMapElemValue()
  11033. }
  11034. ee.EncodeBool(v[int16(k2)])
  11035. }
  11036. } else {
  11037. for k2, v2 := range v {
  11038. if esep {
  11039. ee.WriteMapElemKey()
  11040. }
  11041. ee.EncodeInt(int64(k2))
  11042. if esep {
  11043. ee.WriteMapElemValue()
  11044. }
  11045. ee.EncodeBool(v2)
  11046. }
  11047. }
  11048. ee.WriteMapEnd()
  11049. }
  11050. func (e *Encoder) fastpathEncMapInt32IntfR(f *codecFnInfo, rv reflect.Value) {
  11051. fastpathTV.EncMapInt32IntfV(rv2i(rv).(map[int32]interface{}), e)
  11052. }
  11053. func (_ fastpathT) EncMapInt32IntfV(v map[int32]interface{}, e *Encoder) {
  11054. if v == nil {
  11055. e.e.EncodeNil()
  11056. return
  11057. }
  11058. ee, esep := e.e, e.hh.hasElemSeparators()
  11059. ee.WriteMapStart(len(v))
  11060. if e.h.Canonical {
  11061. v2 := make([]int64, len(v))
  11062. var i int
  11063. for k, _ := range v {
  11064. v2[i] = int64(k)
  11065. i++
  11066. }
  11067. sort.Sort(intSlice(v2))
  11068. for _, k2 := range v2 {
  11069. if esep {
  11070. ee.WriteMapElemKey()
  11071. }
  11072. ee.EncodeInt(int64(int32(k2)))
  11073. if esep {
  11074. ee.WriteMapElemValue()
  11075. }
  11076. e.encode(v[int32(k2)])
  11077. }
  11078. } else {
  11079. for k2, v2 := range v {
  11080. if esep {
  11081. ee.WriteMapElemKey()
  11082. }
  11083. ee.EncodeInt(int64(k2))
  11084. if esep {
  11085. ee.WriteMapElemValue()
  11086. }
  11087. e.encode(v2)
  11088. }
  11089. }
  11090. ee.WriteMapEnd()
  11091. }
  11092. func (e *Encoder) fastpathEncMapInt32StringR(f *codecFnInfo, rv reflect.Value) {
  11093. fastpathTV.EncMapInt32StringV(rv2i(rv).(map[int32]string), e)
  11094. }
  11095. func (_ fastpathT) EncMapInt32StringV(v map[int32]string, e *Encoder) {
  11096. if v == nil {
  11097. e.e.EncodeNil()
  11098. return
  11099. }
  11100. ee, esep := e.e, e.hh.hasElemSeparators()
  11101. ee.WriteMapStart(len(v))
  11102. if e.h.Canonical {
  11103. v2 := make([]int64, len(v))
  11104. var i int
  11105. for k, _ := range v {
  11106. v2[i] = int64(k)
  11107. i++
  11108. }
  11109. sort.Sort(intSlice(v2))
  11110. for _, k2 := range v2 {
  11111. if esep {
  11112. ee.WriteMapElemKey()
  11113. }
  11114. ee.EncodeInt(int64(int32(k2)))
  11115. if esep {
  11116. ee.WriteMapElemValue()
  11117. }
  11118. ee.EncodeString(cUTF8, v[int32(k2)])
  11119. }
  11120. } else {
  11121. for k2, v2 := range v {
  11122. if esep {
  11123. ee.WriteMapElemKey()
  11124. }
  11125. ee.EncodeInt(int64(k2))
  11126. if esep {
  11127. ee.WriteMapElemValue()
  11128. }
  11129. ee.EncodeString(cUTF8, v2)
  11130. }
  11131. }
  11132. ee.WriteMapEnd()
  11133. }
  11134. func (e *Encoder) fastpathEncMapInt32UintR(f *codecFnInfo, rv reflect.Value) {
  11135. fastpathTV.EncMapInt32UintV(rv2i(rv).(map[int32]uint), e)
  11136. }
  11137. func (_ fastpathT) EncMapInt32UintV(v map[int32]uint, e *Encoder) {
  11138. if v == nil {
  11139. e.e.EncodeNil()
  11140. return
  11141. }
  11142. ee, esep := e.e, e.hh.hasElemSeparators()
  11143. ee.WriteMapStart(len(v))
  11144. if e.h.Canonical {
  11145. v2 := make([]int64, len(v))
  11146. var i int
  11147. for k, _ := range v {
  11148. v2[i] = int64(k)
  11149. i++
  11150. }
  11151. sort.Sort(intSlice(v2))
  11152. for _, k2 := range v2 {
  11153. if esep {
  11154. ee.WriteMapElemKey()
  11155. }
  11156. ee.EncodeInt(int64(int32(k2)))
  11157. if esep {
  11158. ee.WriteMapElemValue()
  11159. }
  11160. ee.EncodeUint(uint64(v[int32(k2)]))
  11161. }
  11162. } else {
  11163. for k2, v2 := range v {
  11164. if esep {
  11165. ee.WriteMapElemKey()
  11166. }
  11167. ee.EncodeInt(int64(k2))
  11168. if esep {
  11169. ee.WriteMapElemValue()
  11170. }
  11171. ee.EncodeUint(uint64(v2))
  11172. }
  11173. }
  11174. ee.WriteMapEnd()
  11175. }
  11176. func (e *Encoder) fastpathEncMapInt32Uint8R(f *codecFnInfo, rv reflect.Value) {
  11177. fastpathTV.EncMapInt32Uint8V(rv2i(rv).(map[int32]uint8), e)
  11178. }
  11179. func (_ fastpathT) EncMapInt32Uint8V(v map[int32]uint8, e *Encoder) {
  11180. if v == nil {
  11181. e.e.EncodeNil()
  11182. return
  11183. }
  11184. ee, esep := e.e, e.hh.hasElemSeparators()
  11185. ee.WriteMapStart(len(v))
  11186. if e.h.Canonical {
  11187. v2 := make([]int64, len(v))
  11188. var i int
  11189. for k, _ := range v {
  11190. v2[i] = int64(k)
  11191. i++
  11192. }
  11193. sort.Sort(intSlice(v2))
  11194. for _, k2 := range v2 {
  11195. if esep {
  11196. ee.WriteMapElemKey()
  11197. }
  11198. ee.EncodeInt(int64(int32(k2)))
  11199. if esep {
  11200. ee.WriteMapElemValue()
  11201. }
  11202. ee.EncodeUint(uint64(v[int32(k2)]))
  11203. }
  11204. } else {
  11205. for k2, v2 := range v {
  11206. if esep {
  11207. ee.WriteMapElemKey()
  11208. }
  11209. ee.EncodeInt(int64(k2))
  11210. if esep {
  11211. ee.WriteMapElemValue()
  11212. }
  11213. ee.EncodeUint(uint64(v2))
  11214. }
  11215. }
  11216. ee.WriteMapEnd()
  11217. }
  11218. func (e *Encoder) fastpathEncMapInt32Uint16R(f *codecFnInfo, rv reflect.Value) {
  11219. fastpathTV.EncMapInt32Uint16V(rv2i(rv).(map[int32]uint16), e)
  11220. }
  11221. func (_ fastpathT) EncMapInt32Uint16V(v map[int32]uint16, e *Encoder) {
  11222. if v == nil {
  11223. e.e.EncodeNil()
  11224. return
  11225. }
  11226. ee, esep := e.e, e.hh.hasElemSeparators()
  11227. ee.WriteMapStart(len(v))
  11228. if e.h.Canonical {
  11229. v2 := make([]int64, len(v))
  11230. var i int
  11231. for k, _ := range v {
  11232. v2[i] = int64(k)
  11233. i++
  11234. }
  11235. sort.Sort(intSlice(v2))
  11236. for _, k2 := range v2 {
  11237. if esep {
  11238. ee.WriteMapElemKey()
  11239. }
  11240. ee.EncodeInt(int64(int32(k2)))
  11241. if esep {
  11242. ee.WriteMapElemValue()
  11243. }
  11244. ee.EncodeUint(uint64(v[int32(k2)]))
  11245. }
  11246. } else {
  11247. for k2, v2 := range v {
  11248. if esep {
  11249. ee.WriteMapElemKey()
  11250. }
  11251. ee.EncodeInt(int64(k2))
  11252. if esep {
  11253. ee.WriteMapElemValue()
  11254. }
  11255. ee.EncodeUint(uint64(v2))
  11256. }
  11257. }
  11258. ee.WriteMapEnd()
  11259. }
  11260. func (e *Encoder) fastpathEncMapInt32Uint32R(f *codecFnInfo, rv reflect.Value) {
  11261. fastpathTV.EncMapInt32Uint32V(rv2i(rv).(map[int32]uint32), e)
  11262. }
  11263. func (_ fastpathT) EncMapInt32Uint32V(v map[int32]uint32, e *Encoder) {
  11264. if v == nil {
  11265. e.e.EncodeNil()
  11266. return
  11267. }
  11268. ee, esep := e.e, e.hh.hasElemSeparators()
  11269. ee.WriteMapStart(len(v))
  11270. if e.h.Canonical {
  11271. v2 := make([]int64, len(v))
  11272. var i int
  11273. for k, _ := range v {
  11274. v2[i] = int64(k)
  11275. i++
  11276. }
  11277. sort.Sort(intSlice(v2))
  11278. for _, k2 := range v2 {
  11279. if esep {
  11280. ee.WriteMapElemKey()
  11281. }
  11282. ee.EncodeInt(int64(int32(k2)))
  11283. if esep {
  11284. ee.WriteMapElemValue()
  11285. }
  11286. ee.EncodeUint(uint64(v[int32(k2)]))
  11287. }
  11288. } else {
  11289. for k2, v2 := range v {
  11290. if esep {
  11291. ee.WriteMapElemKey()
  11292. }
  11293. ee.EncodeInt(int64(k2))
  11294. if esep {
  11295. ee.WriteMapElemValue()
  11296. }
  11297. ee.EncodeUint(uint64(v2))
  11298. }
  11299. }
  11300. ee.WriteMapEnd()
  11301. }
  11302. func (e *Encoder) fastpathEncMapInt32Uint64R(f *codecFnInfo, rv reflect.Value) {
  11303. fastpathTV.EncMapInt32Uint64V(rv2i(rv).(map[int32]uint64), e)
  11304. }
  11305. func (_ fastpathT) EncMapInt32Uint64V(v map[int32]uint64, e *Encoder) {
  11306. if v == nil {
  11307. e.e.EncodeNil()
  11308. return
  11309. }
  11310. ee, esep := e.e, e.hh.hasElemSeparators()
  11311. ee.WriteMapStart(len(v))
  11312. if e.h.Canonical {
  11313. v2 := make([]int64, len(v))
  11314. var i int
  11315. for k, _ := range v {
  11316. v2[i] = int64(k)
  11317. i++
  11318. }
  11319. sort.Sort(intSlice(v2))
  11320. for _, k2 := range v2 {
  11321. if esep {
  11322. ee.WriteMapElemKey()
  11323. }
  11324. ee.EncodeInt(int64(int32(k2)))
  11325. if esep {
  11326. ee.WriteMapElemValue()
  11327. }
  11328. ee.EncodeUint(uint64(v[int32(k2)]))
  11329. }
  11330. } else {
  11331. for k2, v2 := range v {
  11332. if esep {
  11333. ee.WriteMapElemKey()
  11334. }
  11335. ee.EncodeInt(int64(k2))
  11336. if esep {
  11337. ee.WriteMapElemValue()
  11338. }
  11339. ee.EncodeUint(uint64(v2))
  11340. }
  11341. }
  11342. ee.WriteMapEnd()
  11343. }
  11344. func (e *Encoder) fastpathEncMapInt32UintptrR(f *codecFnInfo, rv reflect.Value) {
  11345. fastpathTV.EncMapInt32UintptrV(rv2i(rv).(map[int32]uintptr), e)
  11346. }
  11347. func (_ fastpathT) EncMapInt32UintptrV(v map[int32]uintptr, e *Encoder) {
  11348. if v == nil {
  11349. e.e.EncodeNil()
  11350. return
  11351. }
  11352. ee, esep := e.e, e.hh.hasElemSeparators()
  11353. ee.WriteMapStart(len(v))
  11354. if e.h.Canonical {
  11355. v2 := make([]int64, len(v))
  11356. var i int
  11357. for k, _ := range v {
  11358. v2[i] = int64(k)
  11359. i++
  11360. }
  11361. sort.Sort(intSlice(v2))
  11362. for _, k2 := range v2 {
  11363. if esep {
  11364. ee.WriteMapElemKey()
  11365. }
  11366. ee.EncodeInt(int64(int32(k2)))
  11367. if esep {
  11368. ee.WriteMapElemValue()
  11369. }
  11370. e.encode(v[int32(k2)])
  11371. }
  11372. } else {
  11373. for k2, v2 := range v {
  11374. if esep {
  11375. ee.WriteMapElemKey()
  11376. }
  11377. ee.EncodeInt(int64(k2))
  11378. if esep {
  11379. ee.WriteMapElemValue()
  11380. }
  11381. e.encode(v2)
  11382. }
  11383. }
  11384. ee.WriteMapEnd()
  11385. }
  11386. func (e *Encoder) fastpathEncMapInt32IntR(f *codecFnInfo, rv reflect.Value) {
  11387. fastpathTV.EncMapInt32IntV(rv2i(rv).(map[int32]int), e)
  11388. }
  11389. func (_ fastpathT) EncMapInt32IntV(v map[int32]int, e *Encoder) {
  11390. if v == nil {
  11391. e.e.EncodeNil()
  11392. return
  11393. }
  11394. ee, esep := e.e, e.hh.hasElemSeparators()
  11395. ee.WriteMapStart(len(v))
  11396. if e.h.Canonical {
  11397. v2 := make([]int64, len(v))
  11398. var i int
  11399. for k, _ := range v {
  11400. v2[i] = int64(k)
  11401. i++
  11402. }
  11403. sort.Sort(intSlice(v2))
  11404. for _, k2 := range v2 {
  11405. if esep {
  11406. ee.WriteMapElemKey()
  11407. }
  11408. ee.EncodeInt(int64(int32(k2)))
  11409. if esep {
  11410. ee.WriteMapElemValue()
  11411. }
  11412. ee.EncodeInt(int64(v[int32(k2)]))
  11413. }
  11414. } else {
  11415. for k2, v2 := range v {
  11416. if esep {
  11417. ee.WriteMapElemKey()
  11418. }
  11419. ee.EncodeInt(int64(k2))
  11420. if esep {
  11421. ee.WriteMapElemValue()
  11422. }
  11423. ee.EncodeInt(int64(v2))
  11424. }
  11425. }
  11426. ee.WriteMapEnd()
  11427. }
  11428. func (e *Encoder) fastpathEncMapInt32Int8R(f *codecFnInfo, rv reflect.Value) {
  11429. fastpathTV.EncMapInt32Int8V(rv2i(rv).(map[int32]int8), e)
  11430. }
  11431. func (_ fastpathT) EncMapInt32Int8V(v map[int32]int8, e *Encoder) {
  11432. if v == nil {
  11433. e.e.EncodeNil()
  11434. return
  11435. }
  11436. ee, esep := e.e, e.hh.hasElemSeparators()
  11437. ee.WriteMapStart(len(v))
  11438. if e.h.Canonical {
  11439. v2 := make([]int64, len(v))
  11440. var i int
  11441. for k, _ := range v {
  11442. v2[i] = int64(k)
  11443. i++
  11444. }
  11445. sort.Sort(intSlice(v2))
  11446. for _, k2 := range v2 {
  11447. if esep {
  11448. ee.WriteMapElemKey()
  11449. }
  11450. ee.EncodeInt(int64(int32(k2)))
  11451. if esep {
  11452. ee.WriteMapElemValue()
  11453. }
  11454. ee.EncodeInt(int64(v[int32(k2)]))
  11455. }
  11456. } else {
  11457. for k2, v2 := range v {
  11458. if esep {
  11459. ee.WriteMapElemKey()
  11460. }
  11461. ee.EncodeInt(int64(k2))
  11462. if esep {
  11463. ee.WriteMapElemValue()
  11464. }
  11465. ee.EncodeInt(int64(v2))
  11466. }
  11467. }
  11468. ee.WriteMapEnd()
  11469. }
  11470. func (e *Encoder) fastpathEncMapInt32Int16R(f *codecFnInfo, rv reflect.Value) {
  11471. fastpathTV.EncMapInt32Int16V(rv2i(rv).(map[int32]int16), e)
  11472. }
  11473. func (_ fastpathT) EncMapInt32Int16V(v map[int32]int16, e *Encoder) {
  11474. if v == nil {
  11475. e.e.EncodeNil()
  11476. return
  11477. }
  11478. ee, esep := e.e, e.hh.hasElemSeparators()
  11479. ee.WriteMapStart(len(v))
  11480. if e.h.Canonical {
  11481. v2 := make([]int64, len(v))
  11482. var i int
  11483. for k, _ := range v {
  11484. v2[i] = int64(k)
  11485. i++
  11486. }
  11487. sort.Sort(intSlice(v2))
  11488. for _, k2 := range v2 {
  11489. if esep {
  11490. ee.WriteMapElemKey()
  11491. }
  11492. ee.EncodeInt(int64(int32(k2)))
  11493. if esep {
  11494. ee.WriteMapElemValue()
  11495. }
  11496. ee.EncodeInt(int64(v[int32(k2)]))
  11497. }
  11498. } else {
  11499. for k2, v2 := range v {
  11500. if esep {
  11501. ee.WriteMapElemKey()
  11502. }
  11503. ee.EncodeInt(int64(k2))
  11504. if esep {
  11505. ee.WriteMapElemValue()
  11506. }
  11507. ee.EncodeInt(int64(v2))
  11508. }
  11509. }
  11510. ee.WriteMapEnd()
  11511. }
  11512. func (e *Encoder) fastpathEncMapInt32Int32R(f *codecFnInfo, rv reflect.Value) {
  11513. fastpathTV.EncMapInt32Int32V(rv2i(rv).(map[int32]int32), e)
  11514. }
  11515. func (_ fastpathT) EncMapInt32Int32V(v map[int32]int32, e *Encoder) {
  11516. if v == nil {
  11517. e.e.EncodeNil()
  11518. return
  11519. }
  11520. ee, esep := e.e, e.hh.hasElemSeparators()
  11521. ee.WriteMapStart(len(v))
  11522. if e.h.Canonical {
  11523. v2 := make([]int64, len(v))
  11524. var i int
  11525. for k, _ := range v {
  11526. v2[i] = int64(k)
  11527. i++
  11528. }
  11529. sort.Sort(intSlice(v2))
  11530. for _, k2 := range v2 {
  11531. if esep {
  11532. ee.WriteMapElemKey()
  11533. }
  11534. ee.EncodeInt(int64(int32(k2)))
  11535. if esep {
  11536. ee.WriteMapElemValue()
  11537. }
  11538. ee.EncodeInt(int64(v[int32(k2)]))
  11539. }
  11540. } else {
  11541. for k2, v2 := range v {
  11542. if esep {
  11543. ee.WriteMapElemKey()
  11544. }
  11545. ee.EncodeInt(int64(k2))
  11546. if esep {
  11547. ee.WriteMapElemValue()
  11548. }
  11549. ee.EncodeInt(int64(v2))
  11550. }
  11551. }
  11552. ee.WriteMapEnd()
  11553. }
  11554. func (e *Encoder) fastpathEncMapInt32Int64R(f *codecFnInfo, rv reflect.Value) {
  11555. fastpathTV.EncMapInt32Int64V(rv2i(rv).(map[int32]int64), e)
  11556. }
  11557. func (_ fastpathT) EncMapInt32Int64V(v map[int32]int64, e *Encoder) {
  11558. if v == nil {
  11559. e.e.EncodeNil()
  11560. return
  11561. }
  11562. ee, esep := e.e, e.hh.hasElemSeparators()
  11563. ee.WriteMapStart(len(v))
  11564. if e.h.Canonical {
  11565. v2 := make([]int64, len(v))
  11566. var i int
  11567. for k, _ := range v {
  11568. v2[i] = int64(k)
  11569. i++
  11570. }
  11571. sort.Sort(intSlice(v2))
  11572. for _, k2 := range v2 {
  11573. if esep {
  11574. ee.WriteMapElemKey()
  11575. }
  11576. ee.EncodeInt(int64(int32(k2)))
  11577. if esep {
  11578. ee.WriteMapElemValue()
  11579. }
  11580. ee.EncodeInt(int64(v[int32(k2)]))
  11581. }
  11582. } else {
  11583. for k2, v2 := range v {
  11584. if esep {
  11585. ee.WriteMapElemKey()
  11586. }
  11587. ee.EncodeInt(int64(k2))
  11588. if esep {
  11589. ee.WriteMapElemValue()
  11590. }
  11591. ee.EncodeInt(int64(v2))
  11592. }
  11593. }
  11594. ee.WriteMapEnd()
  11595. }
  11596. func (e *Encoder) fastpathEncMapInt32Float32R(f *codecFnInfo, rv reflect.Value) {
  11597. fastpathTV.EncMapInt32Float32V(rv2i(rv).(map[int32]float32), e)
  11598. }
  11599. func (_ fastpathT) EncMapInt32Float32V(v map[int32]float32, e *Encoder) {
  11600. if v == nil {
  11601. e.e.EncodeNil()
  11602. return
  11603. }
  11604. ee, esep := e.e, e.hh.hasElemSeparators()
  11605. ee.WriteMapStart(len(v))
  11606. if e.h.Canonical {
  11607. v2 := make([]int64, len(v))
  11608. var i int
  11609. for k, _ := range v {
  11610. v2[i] = int64(k)
  11611. i++
  11612. }
  11613. sort.Sort(intSlice(v2))
  11614. for _, k2 := range v2 {
  11615. if esep {
  11616. ee.WriteMapElemKey()
  11617. }
  11618. ee.EncodeInt(int64(int32(k2)))
  11619. if esep {
  11620. ee.WriteMapElemValue()
  11621. }
  11622. ee.EncodeFloat32(v[int32(k2)])
  11623. }
  11624. } else {
  11625. for k2, v2 := range v {
  11626. if esep {
  11627. ee.WriteMapElemKey()
  11628. }
  11629. ee.EncodeInt(int64(k2))
  11630. if esep {
  11631. ee.WriteMapElemValue()
  11632. }
  11633. ee.EncodeFloat32(v2)
  11634. }
  11635. }
  11636. ee.WriteMapEnd()
  11637. }
  11638. func (e *Encoder) fastpathEncMapInt32Float64R(f *codecFnInfo, rv reflect.Value) {
  11639. fastpathTV.EncMapInt32Float64V(rv2i(rv).(map[int32]float64), e)
  11640. }
  11641. func (_ fastpathT) EncMapInt32Float64V(v map[int32]float64, e *Encoder) {
  11642. if v == nil {
  11643. e.e.EncodeNil()
  11644. return
  11645. }
  11646. ee, esep := e.e, e.hh.hasElemSeparators()
  11647. ee.WriteMapStart(len(v))
  11648. if e.h.Canonical {
  11649. v2 := make([]int64, len(v))
  11650. var i int
  11651. for k, _ := range v {
  11652. v2[i] = int64(k)
  11653. i++
  11654. }
  11655. sort.Sort(intSlice(v2))
  11656. for _, k2 := range v2 {
  11657. if esep {
  11658. ee.WriteMapElemKey()
  11659. }
  11660. ee.EncodeInt(int64(int32(k2)))
  11661. if esep {
  11662. ee.WriteMapElemValue()
  11663. }
  11664. ee.EncodeFloat64(v[int32(k2)])
  11665. }
  11666. } else {
  11667. for k2, v2 := range v {
  11668. if esep {
  11669. ee.WriteMapElemKey()
  11670. }
  11671. ee.EncodeInt(int64(k2))
  11672. if esep {
  11673. ee.WriteMapElemValue()
  11674. }
  11675. ee.EncodeFloat64(v2)
  11676. }
  11677. }
  11678. ee.WriteMapEnd()
  11679. }
  11680. func (e *Encoder) fastpathEncMapInt32BoolR(f *codecFnInfo, rv reflect.Value) {
  11681. fastpathTV.EncMapInt32BoolV(rv2i(rv).(map[int32]bool), e)
  11682. }
  11683. func (_ fastpathT) EncMapInt32BoolV(v map[int32]bool, e *Encoder) {
  11684. if v == nil {
  11685. e.e.EncodeNil()
  11686. return
  11687. }
  11688. ee, esep := e.e, e.hh.hasElemSeparators()
  11689. ee.WriteMapStart(len(v))
  11690. if e.h.Canonical {
  11691. v2 := make([]int64, len(v))
  11692. var i int
  11693. for k, _ := range v {
  11694. v2[i] = int64(k)
  11695. i++
  11696. }
  11697. sort.Sort(intSlice(v2))
  11698. for _, k2 := range v2 {
  11699. if esep {
  11700. ee.WriteMapElemKey()
  11701. }
  11702. ee.EncodeInt(int64(int32(k2)))
  11703. if esep {
  11704. ee.WriteMapElemValue()
  11705. }
  11706. ee.EncodeBool(v[int32(k2)])
  11707. }
  11708. } else {
  11709. for k2, v2 := range v {
  11710. if esep {
  11711. ee.WriteMapElemKey()
  11712. }
  11713. ee.EncodeInt(int64(k2))
  11714. if esep {
  11715. ee.WriteMapElemValue()
  11716. }
  11717. ee.EncodeBool(v2)
  11718. }
  11719. }
  11720. ee.WriteMapEnd()
  11721. }
  11722. func (e *Encoder) fastpathEncMapInt64IntfR(f *codecFnInfo, rv reflect.Value) {
  11723. fastpathTV.EncMapInt64IntfV(rv2i(rv).(map[int64]interface{}), e)
  11724. }
  11725. func (_ fastpathT) EncMapInt64IntfV(v map[int64]interface{}, e *Encoder) {
  11726. if v == nil {
  11727. e.e.EncodeNil()
  11728. return
  11729. }
  11730. ee, esep := e.e, e.hh.hasElemSeparators()
  11731. ee.WriteMapStart(len(v))
  11732. if e.h.Canonical {
  11733. v2 := make([]int64, len(v))
  11734. var i int
  11735. for k, _ := range v {
  11736. v2[i] = int64(k)
  11737. i++
  11738. }
  11739. sort.Sort(intSlice(v2))
  11740. for _, k2 := range v2 {
  11741. if esep {
  11742. ee.WriteMapElemKey()
  11743. }
  11744. ee.EncodeInt(int64(int64(k2)))
  11745. if esep {
  11746. ee.WriteMapElemValue()
  11747. }
  11748. e.encode(v[int64(k2)])
  11749. }
  11750. } else {
  11751. for k2, v2 := range v {
  11752. if esep {
  11753. ee.WriteMapElemKey()
  11754. }
  11755. ee.EncodeInt(int64(k2))
  11756. if esep {
  11757. ee.WriteMapElemValue()
  11758. }
  11759. e.encode(v2)
  11760. }
  11761. }
  11762. ee.WriteMapEnd()
  11763. }
  11764. func (e *Encoder) fastpathEncMapInt64StringR(f *codecFnInfo, rv reflect.Value) {
  11765. fastpathTV.EncMapInt64StringV(rv2i(rv).(map[int64]string), e)
  11766. }
  11767. func (_ fastpathT) EncMapInt64StringV(v map[int64]string, e *Encoder) {
  11768. if v == nil {
  11769. e.e.EncodeNil()
  11770. return
  11771. }
  11772. ee, esep := e.e, e.hh.hasElemSeparators()
  11773. ee.WriteMapStart(len(v))
  11774. if e.h.Canonical {
  11775. v2 := make([]int64, len(v))
  11776. var i int
  11777. for k, _ := range v {
  11778. v2[i] = int64(k)
  11779. i++
  11780. }
  11781. sort.Sort(intSlice(v2))
  11782. for _, k2 := range v2 {
  11783. if esep {
  11784. ee.WriteMapElemKey()
  11785. }
  11786. ee.EncodeInt(int64(int64(k2)))
  11787. if esep {
  11788. ee.WriteMapElemValue()
  11789. }
  11790. ee.EncodeString(cUTF8, v[int64(k2)])
  11791. }
  11792. } else {
  11793. for k2, v2 := range v {
  11794. if esep {
  11795. ee.WriteMapElemKey()
  11796. }
  11797. ee.EncodeInt(int64(k2))
  11798. if esep {
  11799. ee.WriteMapElemValue()
  11800. }
  11801. ee.EncodeString(cUTF8, v2)
  11802. }
  11803. }
  11804. ee.WriteMapEnd()
  11805. }
  11806. func (e *Encoder) fastpathEncMapInt64UintR(f *codecFnInfo, rv reflect.Value) {
  11807. fastpathTV.EncMapInt64UintV(rv2i(rv).(map[int64]uint), e)
  11808. }
  11809. func (_ fastpathT) EncMapInt64UintV(v map[int64]uint, e *Encoder) {
  11810. if v == nil {
  11811. e.e.EncodeNil()
  11812. return
  11813. }
  11814. ee, esep := e.e, e.hh.hasElemSeparators()
  11815. ee.WriteMapStart(len(v))
  11816. if e.h.Canonical {
  11817. v2 := make([]int64, len(v))
  11818. var i int
  11819. for k, _ := range v {
  11820. v2[i] = int64(k)
  11821. i++
  11822. }
  11823. sort.Sort(intSlice(v2))
  11824. for _, k2 := range v2 {
  11825. if esep {
  11826. ee.WriteMapElemKey()
  11827. }
  11828. ee.EncodeInt(int64(int64(k2)))
  11829. if esep {
  11830. ee.WriteMapElemValue()
  11831. }
  11832. ee.EncodeUint(uint64(v[int64(k2)]))
  11833. }
  11834. } else {
  11835. for k2, v2 := range v {
  11836. if esep {
  11837. ee.WriteMapElemKey()
  11838. }
  11839. ee.EncodeInt(int64(k2))
  11840. if esep {
  11841. ee.WriteMapElemValue()
  11842. }
  11843. ee.EncodeUint(uint64(v2))
  11844. }
  11845. }
  11846. ee.WriteMapEnd()
  11847. }
  11848. func (e *Encoder) fastpathEncMapInt64Uint8R(f *codecFnInfo, rv reflect.Value) {
  11849. fastpathTV.EncMapInt64Uint8V(rv2i(rv).(map[int64]uint8), e)
  11850. }
  11851. func (_ fastpathT) EncMapInt64Uint8V(v map[int64]uint8, e *Encoder) {
  11852. if v == nil {
  11853. e.e.EncodeNil()
  11854. return
  11855. }
  11856. ee, esep := e.e, e.hh.hasElemSeparators()
  11857. ee.WriteMapStart(len(v))
  11858. if e.h.Canonical {
  11859. v2 := make([]int64, len(v))
  11860. var i int
  11861. for k, _ := range v {
  11862. v2[i] = int64(k)
  11863. i++
  11864. }
  11865. sort.Sort(intSlice(v2))
  11866. for _, k2 := range v2 {
  11867. if esep {
  11868. ee.WriteMapElemKey()
  11869. }
  11870. ee.EncodeInt(int64(int64(k2)))
  11871. if esep {
  11872. ee.WriteMapElemValue()
  11873. }
  11874. ee.EncodeUint(uint64(v[int64(k2)]))
  11875. }
  11876. } else {
  11877. for k2, v2 := range v {
  11878. if esep {
  11879. ee.WriteMapElemKey()
  11880. }
  11881. ee.EncodeInt(int64(k2))
  11882. if esep {
  11883. ee.WriteMapElemValue()
  11884. }
  11885. ee.EncodeUint(uint64(v2))
  11886. }
  11887. }
  11888. ee.WriteMapEnd()
  11889. }
  11890. func (e *Encoder) fastpathEncMapInt64Uint16R(f *codecFnInfo, rv reflect.Value) {
  11891. fastpathTV.EncMapInt64Uint16V(rv2i(rv).(map[int64]uint16), e)
  11892. }
  11893. func (_ fastpathT) EncMapInt64Uint16V(v map[int64]uint16, e *Encoder) {
  11894. if v == nil {
  11895. e.e.EncodeNil()
  11896. return
  11897. }
  11898. ee, esep := e.e, e.hh.hasElemSeparators()
  11899. ee.WriteMapStart(len(v))
  11900. if e.h.Canonical {
  11901. v2 := make([]int64, len(v))
  11902. var i int
  11903. for k, _ := range v {
  11904. v2[i] = int64(k)
  11905. i++
  11906. }
  11907. sort.Sort(intSlice(v2))
  11908. for _, k2 := range v2 {
  11909. if esep {
  11910. ee.WriteMapElemKey()
  11911. }
  11912. ee.EncodeInt(int64(int64(k2)))
  11913. if esep {
  11914. ee.WriteMapElemValue()
  11915. }
  11916. ee.EncodeUint(uint64(v[int64(k2)]))
  11917. }
  11918. } else {
  11919. for k2, v2 := range v {
  11920. if esep {
  11921. ee.WriteMapElemKey()
  11922. }
  11923. ee.EncodeInt(int64(k2))
  11924. if esep {
  11925. ee.WriteMapElemValue()
  11926. }
  11927. ee.EncodeUint(uint64(v2))
  11928. }
  11929. }
  11930. ee.WriteMapEnd()
  11931. }
  11932. func (e *Encoder) fastpathEncMapInt64Uint32R(f *codecFnInfo, rv reflect.Value) {
  11933. fastpathTV.EncMapInt64Uint32V(rv2i(rv).(map[int64]uint32), e)
  11934. }
  11935. func (_ fastpathT) EncMapInt64Uint32V(v map[int64]uint32, e *Encoder) {
  11936. if v == nil {
  11937. e.e.EncodeNil()
  11938. return
  11939. }
  11940. ee, esep := e.e, e.hh.hasElemSeparators()
  11941. ee.WriteMapStart(len(v))
  11942. if e.h.Canonical {
  11943. v2 := make([]int64, len(v))
  11944. var i int
  11945. for k, _ := range v {
  11946. v2[i] = int64(k)
  11947. i++
  11948. }
  11949. sort.Sort(intSlice(v2))
  11950. for _, k2 := range v2 {
  11951. if esep {
  11952. ee.WriteMapElemKey()
  11953. }
  11954. ee.EncodeInt(int64(int64(k2)))
  11955. if esep {
  11956. ee.WriteMapElemValue()
  11957. }
  11958. ee.EncodeUint(uint64(v[int64(k2)]))
  11959. }
  11960. } else {
  11961. for k2, v2 := range v {
  11962. if esep {
  11963. ee.WriteMapElemKey()
  11964. }
  11965. ee.EncodeInt(int64(k2))
  11966. if esep {
  11967. ee.WriteMapElemValue()
  11968. }
  11969. ee.EncodeUint(uint64(v2))
  11970. }
  11971. }
  11972. ee.WriteMapEnd()
  11973. }
  11974. func (e *Encoder) fastpathEncMapInt64Uint64R(f *codecFnInfo, rv reflect.Value) {
  11975. fastpathTV.EncMapInt64Uint64V(rv2i(rv).(map[int64]uint64), e)
  11976. }
  11977. func (_ fastpathT) EncMapInt64Uint64V(v map[int64]uint64, e *Encoder) {
  11978. if v == nil {
  11979. e.e.EncodeNil()
  11980. return
  11981. }
  11982. ee, esep := e.e, e.hh.hasElemSeparators()
  11983. ee.WriteMapStart(len(v))
  11984. if e.h.Canonical {
  11985. v2 := make([]int64, len(v))
  11986. var i int
  11987. for k, _ := range v {
  11988. v2[i] = int64(k)
  11989. i++
  11990. }
  11991. sort.Sort(intSlice(v2))
  11992. for _, k2 := range v2 {
  11993. if esep {
  11994. ee.WriteMapElemKey()
  11995. }
  11996. ee.EncodeInt(int64(int64(k2)))
  11997. if esep {
  11998. ee.WriteMapElemValue()
  11999. }
  12000. ee.EncodeUint(uint64(v[int64(k2)]))
  12001. }
  12002. } else {
  12003. for k2, v2 := range v {
  12004. if esep {
  12005. ee.WriteMapElemKey()
  12006. }
  12007. ee.EncodeInt(int64(k2))
  12008. if esep {
  12009. ee.WriteMapElemValue()
  12010. }
  12011. ee.EncodeUint(uint64(v2))
  12012. }
  12013. }
  12014. ee.WriteMapEnd()
  12015. }
  12016. func (e *Encoder) fastpathEncMapInt64UintptrR(f *codecFnInfo, rv reflect.Value) {
  12017. fastpathTV.EncMapInt64UintptrV(rv2i(rv).(map[int64]uintptr), e)
  12018. }
  12019. func (_ fastpathT) EncMapInt64UintptrV(v map[int64]uintptr, e *Encoder) {
  12020. if v == nil {
  12021. e.e.EncodeNil()
  12022. return
  12023. }
  12024. ee, esep := e.e, e.hh.hasElemSeparators()
  12025. ee.WriteMapStart(len(v))
  12026. if e.h.Canonical {
  12027. v2 := make([]int64, len(v))
  12028. var i int
  12029. for k, _ := range v {
  12030. v2[i] = int64(k)
  12031. i++
  12032. }
  12033. sort.Sort(intSlice(v2))
  12034. for _, k2 := range v2 {
  12035. if esep {
  12036. ee.WriteMapElemKey()
  12037. }
  12038. ee.EncodeInt(int64(int64(k2)))
  12039. if esep {
  12040. ee.WriteMapElemValue()
  12041. }
  12042. e.encode(v[int64(k2)])
  12043. }
  12044. } else {
  12045. for k2, v2 := range v {
  12046. if esep {
  12047. ee.WriteMapElemKey()
  12048. }
  12049. ee.EncodeInt(int64(k2))
  12050. if esep {
  12051. ee.WriteMapElemValue()
  12052. }
  12053. e.encode(v2)
  12054. }
  12055. }
  12056. ee.WriteMapEnd()
  12057. }
  12058. func (e *Encoder) fastpathEncMapInt64IntR(f *codecFnInfo, rv reflect.Value) {
  12059. fastpathTV.EncMapInt64IntV(rv2i(rv).(map[int64]int), e)
  12060. }
  12061. func (_ fastpathT) EncMapInt64IntV(v map[int64]int, e *Encoder) {
  12062. if v == nil {
  12063. e.e.EncodeNil()
  12064. return
  12065. }
  12066. ee, esep := e.e, e.hh.hasElemSeparators()
  12067. ee.WriteMapStart(len(v))
  12068. if e.h.Canonical {
  12069. v2 := make([]int64, len(v))
  12070. var i int
  12071. for k, _ := range v {
  12072. v2[i] = int64(k)
  12073. i++
  12074. }
  12075. sort.Sort(intSlice(v2))
  12076. for _, k2 := range v2 {
  12077. if esep {
  12078. ee.WriteMapElemKey()
  12079. }
  12080. ee.EncodeInt(int64(int64(k2)))
  12081. if esep {
  12082. ee.WriteMapElemValue()
  12083. }
  12084. ee.EncodeInt(int64(v[int64(k2)]))
  12085. }
  12086. } else {
  12087. for k2, v2 := range v {
  12088. if esep {
  12089. ee.WriteMapElemKey()
  12090. }
  12091. ee.EncodeInt(int64(k2))
  12092. if esep {
  12093. ee.WriteMapElemValue()
  12094. }
  12095. ee.EncodeInt(int64(v2))
  12096. }
  12097. }
  12098. ee.WriteMapEnd()
  12099. }
  12100. func (e *Encoder) fastpathEncMapInt64Int8R(f *codecFnInfo, rv reflect.Value) {
  12101. fastpathTV.EncMapInt64Int8V(rv2i(rv).(map[int64]int8), e)
  12102. }
  12103. func (_ fastpathT) EncMapInt64Int8V(v map[int64]int8, e *Encoder) {
  12104. if v == nil {
  12105. e.e.EncodeNil()
  12106. return
  12107. }
  12108. ee, esep := e.e, e.hh.hasElemSeparators()
  12109. ee.WriteMapStart(len(v))
  12110. if e.h.Canonical {
  12111. v2 := make([]int64, len(v))
  12112. var i int
  12113. for k, _ := range v {
  12114. v2[i] = int64(k)
  12115. i++
  12116. }
  12117. sort.Sort(intSlice(v2))
  12118. for _, k2 := range v2 {
  12119. if esep {
  12120. ee.WriteMapElemKey()
  12121. }
  12122. ee.EncodeInt(int64(int64(k2)))
  12123. if esep {
  12124. ee.WriteMapElemValue()
  12125. }
  12126. ee.EncodeInt(int64(v[int64(k2)]))
  12127. }
  12128. } else {
  12129. for k2, v2 := range v {
  12130. if esep {
  12131. ee.WriteMapElemKey()
  12132. }
  12133. ee.EncodeInt(int64(k2))
  12134. if esep {
  12135. ee.WriteMapElemValue()
  12136. }
  12137. ee.EncodeInt(int64(v2))
  12138. }
  12139. }
  12140. ee.WriteMapEnd()
  12141. }
  12142. func (e *Encoder) fastpathEncMapInt64Int16R(f *codecFnInfo, rv reflect.Value) {
  12143. fastpathTV.EncMapInt64Int16V(rv2i(rv).(map[int64]int16), e)
  12144. }
  12145. func (_ fastpathT) EncMapInt64Int16V(v map[int64]int16, e *Encoder) {
  12146. if v == nil {
  12147. e.e.EncodeNil()
  12148. return
  12149. }
  12150. ee, esep := e.e, e.hh.hasElemSeparators()
  12151. ee.WriteMapStart(len(v))
  12152. if e.h.Canonical {
  12153. v2 := make([]int64, len(v))
  12154. var i int
  12155. for k, _ := range v {
  12156. v2[i] = int64(k)
  12157. i++
  12158. }
  12159. sort.Sort(intSlice(v2))
  12160. for _, k2 := range v2 {
  12161. if esep {
  12162. ee.WriteMapElemKey()
  12163. }
  12164. ee.EncodeInt(int64(int64(k2)))
  12165. if esep {
  12166. ee.WriteMapElemValue()
  12167. }
  12168. ee.EncodeInt(int64(v[int64(k2)]))
  12169. }
  12170. } else {
  12171. for k2, v2 := range v {
  12172. if esep {
  12173. ee.WriteMapElemKey()
  12174. }
  12175. ee.EncodeInt(int64(k2))
  12176. if esep {
  12177. ee.WriteMapElemValue()
  12178. }
  12179. ee.EncodeInt(int64(v2))
  12180. }
  12181. }
  12182. ee.WriteMapEnd()
  12183. }
  12184. func (e *Encoder) fastpathEncMapInt64Int32R(f *codecFnInfo, rv reflect.Value) {
  12185. fastpathTV.EncMapInt64Int32V(rv2i(rv).(map[int64]int32), e)
  12186. }
  12187. func (_ fastpathT) EncMapInt64Int32V(v map[int64]int32, e *Encoder) {
  12188. if v == nil {
  12189. e.e.EncodeNil()
  12190. return
  12191. }
  12192. ee, esep := e.e, e.hh.hasElemSeparators()
  12193. ee.WriteMapStart(len(v))
  12194. if e.h.Canonical {
  12195. v2 := make([]int64, len(v))
  12196. var i int
  12197. for k, _ := range v {
  12198. v2[i] = int64(k)
  12199. i++
  12200. }
  12201. sort.Sort(intSlice(v2))
  12202. for _, k2 := range v2 {
  12203. if esep {
  12204. ee.WriteMapElemKey()
  12205. }
  12206. ee.EncodeInt(int64(int64(k2)))
  12207. if esep {
  12208. ee.WriteMapElemValue()
  12209. }
  12210. ee.EncodeInt(int64(v[int64(k2)]))
  12211. }
  12212. } else {
  12213. for k2, v2 := range v {
  12214. if esep {
  12215. ee.WriteMapElemKey()
  12216. }
  12217. ee.EncodeInt(int64(k2))
  12218. if esep {
  12219. ee.WriteMapElemValue()
  12220. }
  12221. ee.EncodeInt(int64(v2))
  12222. }
  12223. }
  12224. ee.WriteMapEnd()
  12225. }
  12226. func (e *Encoder) fastpathEncMapInt64Int64R(f *codecFnInfo, rv reflect.Value) {
  12227. fastpathTV.EncMapInt64Int64V(rv2i(rv).(map[int64]int64), e)
  12228. }
  12229. func (_ fastpathT) EncMapInt64Int64V(v map[int64]int64, e *Encoder) {
  12230. if v == nil {
  12231. e.e.EncodeNil()
  12232. return
  12233. }
  12234. ee, esep := e.e, e.hh.hasElemSeparators()
  12235. ee.WriteMapStart(len(v))
  12236. if e.h.Canonical {
  12237. v2 := make([]int64, len(v))
  12238. var i int
  12239. for k, _ := range v {
  12240. v2[i] = int64(k)
  12241. i++
  12242. }
  12243. sort.Sort(intSlice(v2))
  12244. for _, k2 := range v2 {
  12245. if esep {
  12246. ee.WriteMapElemKey()
  12247. }
  12248. ee.EncodeInt(int64(int64(k2)))
  12249. if esep {
  12250. ee.WriteMapElemValue()
  12251. }
  12252. ee.EncodeInt(int64(v[int64(k2)]))
  12253. }
  12254. } else {
  12255. for k2, v2 := range v {
  12256. if esep {
  12257. ee.WriteMapElemKey()
  12258. }
  12259. ee.EncodeInt(int64(k2))
  12260. if esep {
  12261. ee.WriteMapElemValue()
  12262. }
  12263. ee.EncodeInt(int64(v2))
  12264. }
  12265. }
  12266. ee.WriteMapEnd()
  12267. }
  12268. func (e *Encoder) fastpathEncMapInt64Float32R(f *codecFnInfo, rv reflect.Value) {
  12269. fastpathTV.EncMapInt64Float32V(rv2i(rv).(map[int64]float32), e)
  12270. }
  12271. func (_ fastpathT) EncMapInt64Float32V(v map[int64]float32, e *Encoder) {
  12272. if v == nil {
  12273. e.e.EncodeNil()
  12274. return
  12275. }
  12276. ee, esep := e.e, e.hh.hasElemSeparators()
  12277. ee.WriteMapStart(len(v))
  12278. if e.h.Canonical {
  12279. v2 := make([]int64, len(v))
  12280. var i int
  12281. for k, _ := range v {
  12282. v2[i] = int64(k)
  12283. i++
  12284. }
  12285. sort.Sort(intSlice(v2))
  12286. for _, k2 := range v2 {
  12287. if esep {
  12288. ee.WriteMapElemKey()
  12289. }
  12290. ee.EncodeInt(int64(int64(k2)))
  12291. if esep {
  12292. ee.WriteMapElemValue()
  12293. }
  12294. ee.EncodeFloat32(v[int64(k2)])
  12295. }
  12296. } else {
  12297. for k2, v2 := range v {
  12298. if esep {
  12299. ee.WriteMapElemKey()
  12300. }
  12301. ee.EncodeInt(int64(k2))
  12302. if esep {
  12303. ee.WriteMapElemValue()
  12304. }
  12305. ee.EncodeFloat32(v2)
  12306. }
  12307. }
  12308. ee.WriteMapEnd()
  12309. }
  12310. func (e *Encoder) fastpathEncMapInt64Float64R(f *codecFnInfo, rv reflect.Value) {
  12311. fastpathTV.EncMapInt64Float64V(rv2i(rv).(map[int64]float64), e)
  12312. }
  12313. func (_ fastpathT) EncMapInt64Float64V(v map[int64]float64, e *Encoder) {
  12314. if v == nil {
  12315. e.e.EncodeNil()
  12316. return
  12317. }
  12318. ee, esep := e.e, e.hh.hasElemSeparators()
  12319. ee.WriteMapStart(len(v))
  12320. if e.h.Canonical {
  12321. v2 := make([]int64, len(v))
  12322. var i int
  12323. for k, _ := range v {
  12324. v2[i] = int64(k)
  12325. i++
  12326. }
  12327. sort.Sort(intSlice(v2))
  12328. for _, k2 := range v2 {
  12329. if esep {
  12330. ee.WriteMapElemKey()
  12331. }
  12332. ee.EncodeInt(int64(int64(k2)))
  12333. if esep {
  12334. ee.WriteMapElemValue()
  12335. }
  12336. ee.EncodeFloat64(v[int64(k2)])
  12337. }
  12338. } else {
  12339. for k2, v2 := range v {
  12340. if esep {
  12341. ee.WriteMapElemKey()
  12342. }
  12343. ee.EncodeInt(int64(k2))
  12344. if esep {
  12345. ee.WriteMapElemValue()
  12346. }
  12347. ee.EncodeFloat64(v2)
  12348. }
  12349. }
  12350. ee.WriteMapEnd()
  12351. }
  12352. func (e *Encoder) fastpathEncMapInt64BoolR(f *codecFnInfo, rv reflect.Value) {
  12353. fastpathTV.EncMapInt64BoolV(rv2i(rv).(map[int64]bool), e)
  12354. }
  12355. func (_ fastpathT) EncMapInt64BoolV(v map[int64]bool, e *Encoder) {
  12356. if v == nil {
  12357. e.e.EncodeNil()
  12358. return
  12359. }
  12360. ee, esep := e.e, e.hh.hasElemSeparators()
  12361. ee.WriteMapStart(len(v))
  12362. if e.h.Canonical {
  12363. v2 := make([]int64, len(v))
  12364. var i int
  12365. for k, _ := range v {
  12366. v2[i] = int64(k)
  12367. i++
  12368. }
  12369. sort.Sort(intSlice(v2))
  12370. for _, k2 := range v2 {
  12371. if esep {
  12372. ee.WriteMapElemKey()
  12373. }
  12374. ee.EncodeInt(int64(int64(k2)))
  12375. if esep {
  12376. ee.WriteMapElemValue()
  12377. }
  12378. ee.EncodeBool(v[int64(k2)])
  12379. }
  12380. } else {
  12381. for k2, v2 := range v {
  12382. if esep {
  12383. ee.WriteMapElemKey()
  12384. }
  12385. ee.EncodeInt(int64(k2))
  12386. if esep {
  12387. ee.WriteMapElemValue()
  12388. }
  12389. ee.EncodeBool(v2)
  12390. }
  12391. }
  12392. ee.WriteMapEnd()
  12393. }
  12394. func (e *Encoder) fastpathEncMapBoolIntfR(f *codecFnInfo, rv reflect.Value) {
  12395. fastpathTV.EncMapBoolIntfV(rv2i(rv).(map[bool]interface{}), e)
  12396. }
  12397. func (_ fastpathT) EncMapBoolIntfV(v map[bool]interface{}, e *Encoder) {
  12398. if v == nil {
  12399. e.e.EncodeNil()
  12400. return
  12401. }
  12402. ee, esep := e.e, e.hh.hasElemSeparators()
  12403. ee.WriteMapStart(len(v))
  12404. if e.h.Canonical {
  12405. v2 := make([]bool, len(v))
  12406. var i int
  12407. for k, _ := range v {
  12408. v2[i] = bool(k)
  12409. i++
  12410. }
  12411. sort.Sort(boolSlice(v2))
  12412. for _, k2 := range v2 {
  12413. if esep {
  12414. ee.WriteMapElemKey()
  12415. }
  12416. ee.EncodeBool(bool(k2))
  12417. if esep {
  12418. ee.WriteMapElemValue()
  12419. }
  12420. e.encode(v[bool(k2)])
  12421. }
  12422. } else {
  12423. for k2, v2 := range v {
  12424. if esep {
  12425. ee.WriteMapElemKey()
  12426. }
  12427. ee.EncodeBool(k2)
  12428. if esep {
  12429. ee.WriteMapElemValue()
  12430. }
  12431. e.encode(v2)
  12432. }
  12433. }
  12434. ee.WriteMapEnd()
  12435. }
  12436. func (e *Encoder) fastpathEncMapBoolStringR(f *codecFnInfo, rv reflect.Value) {
  12437. fastpathTV.EncMapBoolStringV(rv2i(rv).(map[bool]string), e)
  12438. }
  12439. func (_ fastpathT) EncMapBoolStringV(v map[bool]string, e *Encoder) {
  12440. if v == nil {
  12441. e.e.EncodeNil()
  12442. return
  12443. }
  12444. ee, esep := e.e, e.hh.hasElemSeparators()
  12445. ee.WriteMapStart(len(v))
  12446. if e.h.Canonical {
  12447. v2 := make([]bool, len(v))
  12448. var i int
  12449. for k, _ := range v {
  12450. v2[i] = bool(k)
  12451. i++
  12452. }
  12453. sort.Sort(boolSlice(v2))
  12454. for _, k2 := range v2 {
  12455. if esep {
  12456. ee.WriteMapElemKey()
  12457. }
  12458. ee.EncodeBool(bool(k2))
  12459. if esep {
  12460. ee.WriteMapElemValue()
  12461. }
  12462. ee.EncodeString(cUTF8, v[bool(k2)])
  12463. }
  12464. } else {
  12465. for k2, v2 := range v {
  12466. if esep {
  12467. ee.WriteMapElemKey()
  12468. }
  12469. ee.EncodeBool(k2)
  12470. if esep {
  12471. ee.WriteMapElemValue()
  12472. }
  12473. ee.EncodeString(cUTF8, v2)
  12474. }
  12475. }
  12476. ee.WriteMapEnd()
  12477. }
  12478. func (e *Encoder) fastpathEncMapBoolUintR(f *codecFnInfo, rv reflect.Value) {
  12479. fastpathTV.EncMapBoolUintV(rv2i(rv).(map[bool]uint), e)
  12480. }
  12481. func (_ fastpathT) EncMapBoolUintV(v map[bool]uint, e *Encoder) {
  12482. if v == nil {
  12483. e.e.EncodeNil()
  12484. return
  12485. }
  12486. ee, esep := e.e, e.hh.hasElemSeparators()
  12487. ee.WriteMapStart(len(v))
  12488. if e.h.Canonical {
  12489. v2 := make([]bool, len(v))
  12490. var i int
  12491. for k, _ := range v {
  12492. v2[i] = bool(k)
  12493. i++
  12494. }
  12495. sort.Sort(boolSlice(v2))
  12496. for _, k2 := range v2 {
  12497. if esep {
  12498. ee.WriteMapElemKey()
  12499. }
  12500. ee.EncodeBool(bool(k2))
  12501. if esep {
  12502. ee.WriteMapElemValue()
  12503. }
  12504. ee.EncodeUint(uint64(v[bool(k2)]))
  12505. }
  12506. } else {
  12507. for k2, v2 := range v {
  12508. if esep {
  12509. ee.WriteMapElemKey()
  12510. }
  12511. ee.EncodeBool(k2)
  12512. if esep {
  12513. ee.WriteMapElemValue()
  12514. }
  12515. ee.EncodeUint(uint64(v2))
  12516. }
  12517. }
  12518. ee.WriteMapEnd()
  12519. }
  12520. func (e *Encoder) fastpathEncMapBoolUint8R(f *codecFnInfo, rv reflect.Value) {
  12521. fastpathTV.EncMapBoolUint8V(rv2i(rv).(map[bool]uint8), e)
  12522. }
  12523. func (_ fastpathT) EncMapBoolUint8V(v map[bool]uint8, e *Encoder) {
  12524. if v == nil {
  12525. e.e.EncodeNil()
  12526. return
  12527. }
  12528. ee, esep := e.e, e.hh.hasElemSeparators()
  12529. ee.WriteMapStart(len(v))
  12530. if e.h.Canonical {
  12531. v2 := make([]bool, len(v))
  12532. var i int
  12533. for k, _ := range v {
  12534. v2[i] = bool(k)
  12535. i++
  12536. }
  12537. sort.Sort(boolSlice(v2))
  12538. for _, k2 := range v2 {
  12539. if esep {
  12540. ee.WriteMapElemKey()
  12541. }
  12542. ee.EncodeBool(bool(k2))
  12543. if esep {
  12544. ee.WriteMapElemValue()
  12545. }
  12546. ee.EncodeUint(uint64(v[bool(k2)]))
  12547. }
  12548. } else {
  12549. for k2, v2 := range v {
  12550. if esep {
  12551. ee.WriteMapElemKey()
  12552. }
  12553. ee.EncodeBool(k2)
  12554. if esep {
  12555. ee.WriteMapElemValue()
  12556. }
  12557. ee.EncodeUint(uint64(v2))
  12558. }
  12559. }
  12560. ee.WriteMapEnd()
  12561. }
  12562. func (e *Encoder) fastpathEncMapBoolUint16R(f *codecFnInfo, rv reflect.Value) {
  12563. fastpathTV.EncMapBoolUint16V(rv2i(rv).(map[bool]uint16), e)
  12564. }
  12565. func (_ fastpathT) EncMapBoolUint16V(v map[bool]uint16, e *Encoder) {
  12566. if v == nil {
  12567. e.e.EncodeNil()
  12568. return
  12569. }
  12570. ee, esep := e.e, e.hh.hasElemSeparators()
  12571. ee.WriteMapStart(len(v))
  12572. if e.h.Canonical {
  12573. v2 := make([]bool, len(v))
  12574. var i int
  12575. for k, _ := range v {
  12576. v2[i] = bool(k)
  12577. i++
  12578. }
  12579. sort.Sort(boolSlice(v2))
  12580. for _, k2 := range v2 {
  12581. if esep {
  12582. ee.WriteMapElemKey()
  12583. }
  12584. ee.EncodeBool(bool(k2))
  12585. if esep {
  12586. ee.WriteMapElemValue()
  12587. }
  12588. ee.EncodeUint(uint64(v[bool(k2)]))
  12589. }
  12590. } else {
  12591. for k2, v2 := range v {
  12592. if esep {
  12593. ee.WriteMapElemKey()
  12594. }
  12595. ee.EncodeBool(k2)
  12596. if esep {
  12597. ee.WriteMapElemValue()
  12598. }
  12599. ee.EncodeUint(uint64(v2))
  12600. }
  12601. }
  12602. ee.WriteMapEnd()
  12603. }
  12604. func (e *Encoder) fastpathEncMapBoolUint32R(f *codecFnInfo, rv reflect.Value) {
  12605. fastpathTV.EncMapBoolUint32V(rv2i(rv).(map[bool]uint32), e)
  12606. }
  12607. func (_ fastpathT) EncMapBoolUint32V(v map[bool]uint32, e *Encoder) {
  12608. if v == nil {
  12609. e.e.EncodeNil()
  12610. return
  12611. }
  12612. ee, esep := e.e, e.hh.hasElemSeparators()
  12613. ee.WriteMapStart(len(v))
  12614. if e.h.Canonical {
  12615. v2 := make([]bool, len(v))
  12616. var i int
  12617. for k, _ := range v {
  12618. v2[i] = bool(k)
  12619. i++
  12620. }
  12621. sort.Sort(boolSlice(v2))
  12622. for _, k2 := range v2 {
  12623. if esep {
  12624. ee.WriteMapElemKey()
  12625. }
  12626. ee.EncodeBool(bool(k2))
  12627. if esep {
  12628. ee.WriteMapElemValue()
  12629. }
  12630. ee.EncodeUint(uint64(v[bool(k2)]))
  12631. }
  12632. } else {
  12633. for k2, v2 := range v {
  12634. if esep {
  12635. ee.WriteMapElemKey()
  12636. }
  12637. ee.EncodeBool(k2)
  12638. if esep {
  12639. ee.WriteMapElemValue()
  12640. }
  12641. ee.EncodeUint(uint64(v2))
  12642. }
  12643. }
  12644. ee.WriteMapEnd()
  12645. }
  12646. func (e *Encoder) fastpathEncMapBoolUint64R(f *codecFnInfo, rv reflect.Value) {
  12647. fastpathTV.EncMapBoolUint64V(rv2i(rv).(map[bool]uint64), e)
  12648. }
  12649. func (_ fastpathT) EncMapBoolUint64V(v map[bool]uint64, e *Encoder) {
  12650. if v == nil {
  12651. e.e.EncodeNil()
  12652. return
  12653. }
  12654. ee, esep := e.e, e.hh.hasElemSeparators()
  12655. ee.WriteMapStart(len(v))
  12656. if e.h.Canonical {
  12657. v2 := make([]bool, len(v))
  12658. var i int
  12659. for k, _ := range v {
  12660. v2[i] = bool(k)
  12661. i++
  12662. }
  12663. sort.Sort(boolSlice(v2))
  12664. for _, k2 := range v2 {
  12665. if esep {
  12666. ee.WriteMapElemKey()
  12667. }
  12668. ee.EncodeBool(bool(k2))
  12669. if esep {
  12670. ee.WriteMapElemValue()
  12671. }
  12672. ee.EncodeUint(uint64(v[bool(k2)]))
  12673. }
  12674. } else {
  12675. for k2, v2 := range v {
  12676. if esep {
  12677. ee.WriteMapElemKey()
  12678. }
  12679. ee.EncodeBool(k2)
  12680. if esep {
  12681. ee.WriteMapElemValue()
  12682. }
  12683. ee.EncodeUint(uint64(v2))
  12684. }
  12685. }
  12686. ee.WriteMapEnd()
  12687. }
  12688. func (e *Encoder) fastpathEncMapBoolUintptrR(f *codecFnInfo, rv reflect.Value) {
  12689. fastpathTV.EncMapBoolUintptrV(rv2i(rv).(map[bool]uintptr), e)
  12690. }
  12691. func (_ fastpathT) EncMapBoolUintptrV(v map[bool]uintptr, e *Encoder) {
  12692. if v == nil {
  12693. e.e.EncodeNil()
  12694. return
  12695. }
  12696. ee, esep := e.e, e.hh.hasElemSeparators()
  12697. ee.WriteMapStart(len(v))
  12698. if e.h.Canonical {
  12699. v2 := make([]bool, len(v))
  12700. var i int
  12701. for k, _ := range v {
  12702. v2[i] = bool(k)
  12703. i++
  12704. }
  12705. sort.Sort(boolSlice(v2))
  12706. for _, k2 := range v2 {
  12707. if esep {
  12708. ee.WriteMapElemKey()
  12709. }
  12710. ee.EncodeBool(bool(k2))
  12711. if esep {
  12712. ee.WriteMapElemValue()
  12713. }
  12714. e.encode(v[bool(k2)])
  12715. }
  12716. } else {
  12717. for k2, v2 := range v {
  12718. if esep {
  12719. ee.WriteMapElemKey()
  12720. }
  12721. ee.EncodeBool(k2)
  12722. if esep {
  12723. ee.WriteMapElemValue()
  12724. }
  12725. e.encode(v2)
  12726. }
  12727. }
  12728. ee.WriteMapEnd()
  12729. }
  12730. func (e *Encoder) fastpathEncMapBoolIntR(f *codecFnInfo, rv reflect.Value) {
  12731. fastpathTV.EncMapBoolIntV(rv2i(rv).(map[bool]int), e)
  12732. }
  12733. func (_ fastpathT) EncMapBoolIntV(v map[bool]int, e *Encoder) {
  12734. if v == nil {
  12735. e.e.EncodeNil()
  12736. return
  12737. }
  12738. ee, esep := e.e, e.hh.hasElemSeparators()
  12739. ee.WriteMapStart(len(v))
  12740. if e.h.Canonical {
  12741. v2 := make([]bool, len(v))
  12742. var i int
  12743. for k, _ := range v {
  12744. v2[i] = bool(k)
  12745. i++
  12746. }
  12747. sort.Sort(boolSlice(v2))
  12748. for _, k2 := range v2 {
  12749. if esep {
  12750. ee.WriteMapElemKey()
  12751. }
  12752. ee.EncodeBool(bool(k2))
  12753. if esep {
  12754. ee.WriteMapElemValue()
  12755. }
  12756. ee.EncodeInt(int64(v[bool(k2)]))
  12757. }
  12758. } else {
  12759. for k2, v2 := range v {
  12760. if esep {
  12761. ee.WriteMapElemKey()
  12762. }
  12763. ee.EncodeBool(k2)
  12764. if esep {
  12765. ee.WriteMapElemValue()
  12766. }
  12767. ee.EncodeInt(int64(v2))
  12768. }
  12769. }
  12770. ee.WriteMapEnd()
  12771. }
  12772. func (e *Encoder) fastpathEncMapBoolInt8R(f *codecFnInfo, rv reflect.Value) {
  12773. fastpathTV.EncMapBoolInt8V(rv2i(rv).(map[bool]int8), e)
  12774. }
  12775. func (_ fastpathT) EncMapBoolInt8V(v map[bool]int8, e *Encoder) {
  12776. if v == nil {
  12777. e.e.EncodeNil()
  12778. return
  12779. }
  12780. ee, esep := e.e, e.hh.hasElemSeparators()
  12781. ee.WriteMapStart(len(v))
  12782. if e.h.Canonical {
  12783. v2 := make([]bool, len(v))
  12784. var i int
  12785. for k, _ := range v {
  12786. v2[i] = bool(k)
  12787. i++
  12788. }
  12789. sort.Sort(boolSlice(v2))
  12790. for _, k2 := range v2 {
  12791. if esep {
  12792. ee.WriteMapElemKey()
  12793. }
  12794. ee.EncodeBool(bool(k2))
  12795. if esep {
  12796. ee.WriteMapElemValue()
  12797. }
  12798. ee.EncodeInt(int64(v[bool(k2)]))
  12799. }
  12800. } else {
  12801. for k2, v2 := range v {
  12802. if esep {
  12803. ee.WriteMapElemKey()
  12804. }
  12805. ee.EncodeBool(k2)
  12806. if esep {
  12807. ee.WriteMapElemValue()
  12808. }
  12809. ee.EncodeInt(int64(v2))
  12810. }
  12811. }
  12812. ee.WriteMapEnd()
  12813. }
  12814. func (e *Encoder) fastpathEncMapBoolInt16R(f *codecFnInfo, rv reflect.Value) {
  12815. fastpathTV.EncMapBoolInt16V(rv2i(rv).(map[bool]int16), e)
  12816. }
  12817. func (_ fastpathT) EncMapBoolInt16V(v map[bool]int16, e *Encoder) {
  12818. if v == nil {
  12819. e.e.EncodeNil()
  12820. return
  12821. }
  12822. ee, esep := e.e, e.hh.hasElemSeparators()
  12823. ee.WriteMapStart(len(v))
  12824. if e.h.Canonical {
  12825. v2 := make([]bool, len(v))
  12826. var i int
  12827. for k, _ := range v {
  12828. v2[i] = bool(k)
  12829. i++
  12830. }
  12831. sort.Sort(boolSlice(v2))
  12832. for _, k2 := range v2 {
  12833. if esep {
  12834. ee.WriteMapElemKey()
  12835. }
  12836. ee.EncodeBool(bool(k2))
  12837. if esep {
  12838. ee.WriteMapElemValue()
  12839. }
  12840. ee.EncodeInt(int64(v[bool(k2)]))
  12841. }
  12842. } else {
  12843. for k2, v2 := range v {
  12844. if esep {
  12845. ee.WriteMapElemKey()
  12846. }
  12847. ee.EncodeBool(k2)
  12848. if esep {
  12849. ee.WriteMapElemValue()
  12850. }
  12851. ee.EncodeInt(int64(v2))
  12852. }
  12853. }
  12854. ee.WriteMapEnd()
  12855. }
  12856. func (e *Encoder) fastpathEncMapBoolInt32R(f *codecFnInfo, rv reflect.Value) {
  12857. fastpathTV.EncMapBoolInt32V(rv2i(rv).(map[bool]int32), e)
  12858. }
  12859. func (_ fastpathT) EncMapBoolInt32V(v map[bool]int32, e *Encoder) {
  12860. if v == nil {
  12861. e.e.EncodeNil()
  12862. return
  12863. }
  12864. ee, esep := e.e, e.hh.hasElemSeparators()
  12865. ee.WriteMapStart(len(v))
  12866. if e.h.Canonical {
  12867. v2 := make([]bool, len(v))
  12868. var i int
  12869. for k, _ := range v {
  12870. v2[i] = bool(k)
  12871. i++
  12872. }
  12873. sort.Sort(boolSlice(v2))
  12874. for _, k2 := range v2 {
  12875. if esep {
  12876. ee.WriteMapElemKey()
  12877. }
  12878. ee.EncodeBool(bool(k2))
  12879. if esep {
  12880. ee.WriteMapElemValue()
  12881. }
  12882. ee.EncodeInt(int64(v[bool(k2)]))
  12883. }
  12884. } else {
  12885. for k2, v2 := range v {
  12886. if esep {
  12887. ee.WriteMapElemKey()
  12888. }
  12889. ee.EncodeBool(k2)
  12890. if esep {
  12891. ee.WriteMapElemValue()
  12892. }
  12893. ee.EncodeInt(int64(v2))
  12894. }
  12895. }
  12896. ee.WriteMapEnd()
  12897. }
  12898. func (e *Encoder) fastpathEncMapBoolInt64R(f *codecFnInfo, rv reflect.Value) {
  12899. fastpathTV.EncMapBoolInt64V(rv2i(rv).(map[bool]int64), e)
  12900. }
  12901. func (_ fastpathT) EncMapBoolInt64V(v map[bool]int64, e *Encoder) {
  12902. if v == nil {
  12903. e.e.EncodeNil()
  12904. return
  12905. }
  12906. ee, esep := e.e, e.hh.hasElemSeparators()
  12907. ee.WriteMapStart(len(v))
  12908. if e.h.Canonical {
  12909. v2 := make([]bool, len(v))
  12910. var i int
  12911. for k, _ := range v {
  12912. v2[i] = bool(k)
  12913. i++
  12914. }
  12915. sort.Sort(boolSlice(v2))
  12916. for _, k2 := range v2 {
  12917. if esep {
  12918. ee.WriteMapElemKey()
  12919. }
  12920. ee.EncodeBool(bool(k2))
  12921. if esep {
  12922. ee.WriteMapElemValue()
  12923. }
  12924. ee.EncodeInt(int64(v[bool(k2)]))
  12925. }
  12926. } else {
  12927. for k2, v2 := range v {
  12928. if esep {
  12929. ee.WriteMapElemKey()
  12930. }
  12931. ee.EncodeBool(k2)
  12932. if esep {
  12933. ee.WriteMapElemValue()
  12934. }
  12935. ee.EncodeInt(int64(v2))
  12936. }
  12937. }
  12938. ee.WriteMapEnd()
  12939. }
  12940. func (e *Encoder) fastpathEncMapBoolFloat32R(f *codecFnInfo, rv reflect.Value) {
  12941. fastpathTV.EncMapBoolFloat32V(rv2i(rv).(map[bool]float32), e)
  12942. }
  12943. func (_ fastpathT) EncMapBoolFloat32V(v map[bool]float32, e *Encoder) {
  12944. if v == nil {
  12945. e.e.EncodeNil()
  12946. return
  12947. }
  12948. ee, esep := e.e, e.hh.hasElemSeparators()
  12949. ee.WriteMapStart(len(v))
  12950. if e.h.Canonical {
  12951. v2 := make([]bool, len(v))
  12952. var i int
  12953. for k, _ := range v {
  12954. v2[i] = bool(k)
  12955. i++
  12956. }
  12957. sort.Sort(boolSlice(v2))
  12958. for _, k2 := range v2 {
  12959. if esep {
  12960. ee.WriteMapElemKey()
  12961. }
  12962. ee.EncodeBool(bool(k2))
  12963. if esep {
  12964. ee.WriteMapElemValue()
  12965. }
  12966. ee.EncodeFloat32(v[bool(k2)])
  12967. }
  12968. } else {
  12969. for k2, v2 := range v {
  12970. if esep {
  12971. ee.WriteMapElemKey()
  12972. }
  12973. ee.EncodeBool(k2)
  12974. if esep {
  12975. ee.WriteMapElemValue()
  12976. }
  12977. ee.EncodeFloat32(v2)
  12978. }
  12979. }
  12980. ee.WriteMapEnd()
  12981. }
  12982. func (e *Encoder) fastpathEncMapBoolFloat64R(f *codecFnInfo, rv reflect.Value) {
  12983. fastpathTV.EncMapBoolFloat64V(rv2i(rv).(map[bool]float64), e)
  12984. }
  12985. func (_ fastpathT) EncMapBoolFloat64V(v map[bool]float64, e *Encoder) {
  12986. if v == nil {
  12987. e.e.EncodeNil()
  12988. return
  12989. }
  12990. ee, esep := e.e, e.hh.hasElemSeparators()
  12991. ee.WriteMapStart(len(v))
  12992. if e.h.Canonical {
  12993. v2 := make([]bool, len(v))
  12994. var i int
  12995. for k, _ := range v {
  12996. v2[i] = bool(k)
  12997. i++
  12998. }
  12999. sort.Sort(boolSlice(v2))
  13000. for _, k2 := range v2 {
  13001. if esep {
  13002. ee.WriteMapElemKey()
  13003. }
  13004. ee.EncodeBool(bool(k2))
  13005. if esep {
  13006. ee.WriteMapElemValue()
  13007. }
  13008. ee.EncodeFloat64(v[bool(k2)])
  13009. }
  13010. } else {
  13011. for k2, v2 := range v {
  13012. if esep {
  13013. ee.WriteMapElemKey()
  13014. }
  13015. ee.EncodeBool(k2)
  13016. if esep {
  13017. ee.WriteMapElemValue()
  13018. }
  13019. ee.EncodeFloat64(v2)
  13020. }
  13021. }
  13022. ee.WriteMapEnd()
  13023. }
  13024. func (e *Encoder) fastpathEncMapBoolBoolR(f *codecFnInfo, rv reflect.Value) {
  13025. fastpathTV.EncMapBoolBoolV(rv2i(rv).(map[bool]bool), e)
  13026. }
  13027. func (_ fastpathT) EncMapBoolBoolV(v map[bool]bool, e *Encoder) {
  13028. if v == nil {
  13029. e.e.EncodeNil()
  13030. return
  13031. }
  13032. ee, esep := e.e, e.hh.hasElemSeparators()
  13033. ee.WriteMapStart(len(v))
  13034. if e.h.Canonical {
  13035. v2 := make([]bool, len(v))
  13036. var i int
  13037. for k, _ := range v {
  13038. v2[i] = bool(k)
  13039. i++
  13040. }
  13041. sort.Sort(boolSlice(v2))
  13042. for _, k2 := range v2 {
  13043. if esep {
  13044. ee.WriteMapElemKey()
  13045. }
  13046. ee.EncodeBool(bool(k2))
  13047. if esep {
  13048. ee.WriteMapElemValue()
  13049. }
  13050. ee.EncodeBool(v[bool(k2)])
  13051. }
  13052. } else {
  13053. for k2, v2 := range v {
  13054. if esep {
  13055. ee.WriteMapElemKey()
  13056. }
  13057. ee.EncodeBool(k2)
  13058. if esep {
  13059. ee.WriteMapElemValue()
  13060. }
  13061. ee.EncodeBool(v2)
  13062. }
  13063. }
  13064. ee.WriteMapEnd()
  13065. }
  13066. // -- decode
  13067. // -- -- fast path type switch
  13068. func fastpathDecodeTypeSwitch(iv interface{}, d *Decoder) bool {
  13069. switch v := iv.(type) {
  13070. case []interface{}:
  13071. fastpathTV.DecSliceIntfV(v, false, d)
  13072. case *[]interface{}:
  13073. if v2, changed2 := fastpathTV.DecSliceIntfV(*v, true, d); changed2 {
  13074. *v = v2
  13075. }
  13076. case map[interface{}]interface{}:
  13077. fastpathTV.DecMapIntfIntfV(v, false, d)
  13078. case *map[interface{}]interface{}:
  13079. if v2, changed2 := fastpathTV.DecMapIntfIntfV(*v, true, d); changed2 {
  13080. *v = v2
  13081. }
  13082. case map[interface{}]string:
  13083. fastpathTV.DecMapIntfStringV(v, false, d)
  13084. case *map[interface{}]string:
  13085. if v2, changed2 := fastpathTV.DecMapIntfStringV(*v, true, d); changed2 {
  13086. *v = v2
  13087. }
  13088. case map[interface{}]uint:
  13089. fastpathTV.DecMapIntfUintV(v, false, d)
  13090. case *map[interface{}]uint:
  13091. if v2, changed2 := fastpathTV.DecMapIntfUintV(*v, true, d); changed2 {
  13092. *v = v2
  13093. }
  13094. case map[interface{}]uint8:
  13095. fastpathTV.DecMapIntfUint8V(v, false, d)
  13096. case *map[interface{}]uint8:
  13097. if v2, changed2 := fastpathTV.DecMapIntfUint8V(*v, true, d); changed2 {
  13098. *v = v2
  13099. }
  13100. case map[interface{}]uint16:
  13101. fastpathTV.DecMapIntfUint16V(v, false, d)
  13102. case *map[interface{}]uint16:
  13103. if v2, changed2 := fastpathTV.DecMapIntfUint16V(*v, true, d); changed2 {
  13104. *v = v2
  13105. }
  13106. case map[interface{}]uint32:
  13107. fastpathTV.DecMapIntfUint32V(v, false, d)
  13108. case *map[interface{}]uint32:
  13109. if v2, changed2 := fastpathTV.DecMapIntfUint32V(*v, true, d); changed2 {
  13110. *v = v2
  13111. }
  13112. case map[interface{}]uint64:
  13113. fastpathTV.DecMapIntfUint64V(v, false, d)
  13114. case *map[interface{}]uint64:
  13115. if v2, changed2 := fastpathTV.DecMapIntfUint64V(*v, true, d); changed2 {
  13116. *v = v2
  13117. }
  13118. case map[interface{}]uintptr:
  13119. fastpathTV.DecMapIntfUintptrV(v, false, d)
  13120. case *map[interface{}]uintptr:
  13121. if v2, changed2 := fastpathTV.DecMapIntfUintptrV(*v, true, d); changed2 {
  13122. *v = v2
  13123. }
  13124. case map[interface{}]int:
  13125. fastpathTV.DecMapIntfIntV(v, false, d)
  13126. case *map[interface{}]int:
  13127. if v2, changed2 := fastpathTV.DecMapIntfIntV(*v, true, d); changed2 {
  13128. *v = v2
  13129. }
  13130. case map[interface{}]int8:
  13131. fastpathTV.DecMapIntfInt8V(v, false, d)
  13132. case *map[interface{}]int8:
  13133. if v2, changed2 := fastpathTV.DecMapIntfInt8V(*v, true, d); changed2 {
  13134. *v = v2
  13135. }
  13136. case map[interface{}]int16:
  13137. fastpathTV.DecMapIntfInt16V(v, false, d)
  13138. case *map[interface{}]int16:
  13139. if v2, changed2 := fastpathTV.DecMapIntfInt16V(*v, true, d); changed2 {
  13140. *v = v2
  13141. }
  13142. case map[interface{}]int32:
  13143. fastpathTV.DecMapIntfInt32V(v, false, d)
  13144. case *map[interface{}]int32:
  13145. if v2, changed2 := fastpathTV.DecMapIntfInt32V(*v, true, d); changed2 {
  13146. *v = v2
  13147. }
  13148. case map[interface{}]int64:
  13149. fastpathTV.DecMapIntfInt64V(v, false, d)
  13150. case *map[interface{}]int64:
  13151. if v2, changed2 := fastpathTV.DecMapIntfInt64V(*v, true, d); changed2 {
  13152. *v = v2
  13153. }
  13154. case map[interface{}]float32:
  13155. fastpathTV.DecMapIntfFloat32V(v, false, d)
  13156. case *map[interface{}]float32:
  13157. if v2, changed2 := fastpathTV.DecMapIntfFloat32V(*v, true, d); changed2 {
  13158. *v = v2
  13159. }
  13160. case map[interface{}]float64:
  13161. fastpathTV.DecMapIntfFloat64V(v, false, d)
  13162. case *map[interface{}]float64:
  13163. if v2, changed2 := fastpathTV.DecMapIntfFloat64V(*v, true, d); changed2 {
  13164. *v = v2
  13165. }
  13166. case map[interface{}]bool:
  13167. fastpathTV.DecMapIntfBoolV(v, false, d)
  13168. case *map[interface{}]bool:
  13169. if v2, changed2 := fastpathTV.DecMapIntfBoolV(*v, true, d); changed2 {
  13170. *v = v2
  13171. }
  13172. case []string:
  13173. fastpathTV.DecSliceStringV(v, false, d)
  13174. case *[]string:
  13175. if v2, changed2 := fastpathTV.DecSliceStringV(*v, true, d); changed2 {
  13176. *v = v2
  13177. }
  13178. case map[string]interface{}:
  13179. fastpathTV.DecMapStringIntfV(v, false, d)
  13180. case *map[string]interface{}:
  13181. if v2, changed2 := fastpathTV.DecMapStringIntfV(*v, true, d); changed2 {
  13182. *v = v2
  13183. }
  13184. case map[string]string:
  13185. fastpathTV.DecMapStringStringV(v, false, d)
  13186. case *map[string]string:
  13187. if v2, changed2 := fastpathTV.DecMapStringStringV(*v, true, d); changed2 {
  13188. *v = v2
  13189. }
  13190. case map[string]uint:
  13191. fastpathTV.DecMapStringUintV(v, false, d)
  13192. case *map[string]uint:
  13193. if v2, changed2 := fastpathTV.DecMapStringUintV(*v, true, d); changed2 {
  13194. *v = v2
  13195. }
  13196. case map[string]uint8:
  13197. fastpathTV.DecMapStringUint8V(v, false, d)
  13198. case *map[string]uint8:
  13199. if v2, changed2 := fastpathTV.DecMapStringUint8V(*v, true, d); changed2 {
  13200. *v = v2
  13201. }
  13202. case map[string]uint16:
  13203. fastpathTV.DecMapStringUint16V(v, false, d)
  13204. case *map[string]uint16:
  13205. if v2, changed2 := fastpathTV.DecMapStringUint16V(*v, true, d); changed2 {
  13206. *v = v2
  13207. }
  13208. case map[string]uint32:
  13209. fastpathTV.DecMapStringUint32V(v, false, d)
  13210. case *map[string]uint32:
  13211. if v2, changed2 := fastpathTV.DecMapStringUint32V(*v, true, d); changed2 {
  13212. *v = v2
  13213. }
  13214. case map[string]uint64:
  13215. fastpathTV.DecMapStringUint64V(v, false, d)
  13216. case *map[string]uint64:
  13217. if v2, changed2 := fastpathTV.DecMapStringUint64V(*v, true, d); changed2 {
  13218. *v = v2
  13219. }
  13220. case map[string]uintptr:
  13221. fastpathTV.DecMapStringUintptrV(v, false, d)
  13222. case *map[string]uintptr:
  13223. if v2, changed2 := fastpathTV.DecMapStringUintptrV(*v, true, d); changed2 {
  13224. *v = v2
  13225. }
  13226. case map[string]int:
  13227. fastpathTV.DecMapStringIntV(v, false, d)
  13228. case *map[string]int:
  13229. if v2, changed2 := fastpathTV.DecMapStringIntV(*v, true, d); changed2 {
  13230. *v = v2
  13231. }
  13232. case map[string]int8:
  13233. fastpathTV.DecMapStringInt8V(v, false, d)
  13234. case *map[string]int8:
  13235. if v2, changed2 := fastpathTV.DecMapStringInt8V(*v, true, d); changed2 {
  13236. *v = v2
  13237. }
  13238. case map[string]int16:
  13239. fastpathTV.DecMapStringInt16V(v, false, d)
  13240. case *map[string]int16:
  13241. if v2, changed2 := fastpathTV.DecMapStringInt16V(*v, true, d); changed2 {
  13242. *v = v2
  13243. }
  13244. case map[string]int32:
  13245. fastpathTV.DecMapStringInt32V(v, false, d)
  13246. case *map[string]int32:
  13247. if v2, changed2 := fastpathTV.DecMapStringInt32V(*v, true, d); changed2 {
  13248. *v = v2
  13249. }
  13250. case map[string]int64:
  13251. fastpathTV.DecMapStringInt64V(v, false, d)
  13252. case *map[string]int64:
  13253. if v2, changed2 := fastpathTV.DecMapStringInt64V(*v, true, d); changed2 {
  13254. *v = v2
  13255. }
  13256. case map[string]float32:
  13257. fastpathTV.DecMapStringFloat32V(v, false, d)
  13258. case *map[string]float32:
  13259. if v2, changed2 := fastpathTV.DecMapStringFloat32V(*v, true, d); changed2 {
  13260. *v = v2
  13261. }
  13262. case map[string]float64:
  13263. fastpathTV.DecMapStringFloat64V(v, false, d)
  13264. case *map[string]float64:
  13265. if v2, changed2 := fastpathTV.DecMapStringFloat64V(*v, true, d); changed2 {
  13266. *v = v2
  13267. }
  13268. case map[string]bool:
  13269. fastpathTV.DecMapStringBoolV(v, false, d)
  13270. case *map[string]bool:
  13271. if v2, changed2 := fastpathTV.DecMapStringBoolV(*v, true, d); changed2 {
  13272. *v = v2
  13273. }
  13274. case []float32:
  13275. fastpathTV.DecSliceFloat32V(v, false, d)
  13276. case *[]float32:
  13277. if v2, changed2 := fastpathTV.DecSliceFloat32V(*v, true, d); changed2 {
  13278. *v = v2
  13279. }
  13280. case map[float32]interface{}:
  13281. fastpathTV.DecMapFloat32IntfV(v, false, d)
  13282. case *map[float32]interface{}:
  13283. if v2, changed2 := fastpathTV.DecMapFloat32IntfV(*v, true, d); changed2 {
  13284. *v = v2
  13285. }
  13286. case map[float32]string:
  13287. fastpathTV.DecMapFloat32StringV(v, false, d)
  13288. case *map[float32]string:
  13289. if v2, changed2 := fastpathTV.DecMapFloat32StringV(*v, true, d); changed2 {
  13290. *v = v2
  13291. }
  13292. case map[float32]uint:
  13293. fastpathTV.DecMapFloat32UintV(v, false, d)
  13294. case *map[float32]uint:
  13295. if v2, changed2 := fastpathTV.DecMapFloat32UintV(*v, true, d); changed2 {
  13296. *v = v2
  13297. }
  13298. case map[float32]uint8:
  13299. fastpathTV.DecMapFloat32Uint8V(v, false, d)
  13300. case *map[float32]uint8:
  13301. if v2, changed2 := fastpathTV.DecMapFloat32Uint8V(*v, true, d); changed2 {
  13302. *v = v2
  13303. }
  13304. case map[float32]uint16:
  13305. fastpathTV.DecMapFloat32Uint16V(v, false, d)
  13306. case *map[float32]uint16:
  13307. if v2, changed2 := fastpathTV.DecMapFloat32Uint16V(*v, true, d); changed2 {
  13308. *v = v2
  13309. }
  13310. case map[float32]uint32:
  13311. fastpathTV.DecMapFloat32Uint32V(v, false, d)
  13312. case *map[float32]uint32:
  13313. if v2, changed2 := fastpathTV.DecMapFloat32Uint32V(*v, true, d); changed2 {
  13314. *v = v2
  13315. }
  13316. case map[float32]uint64:
  13317. fastpathTV.DecMapFloat32Uint64V(v, false, d)
  13318. case *map[float32]uint64:
  13319. if v2, changed2 := fastpathTV.DecMapFloat32Uint64V(*v, true, d); changed2 {
  13320. *v = v2
  13321. }
  13322. case map[float32]uintptr:
  13323. fastpathTV.DecMapFloat32UintptrV(v, false, d)
  13324. case *map[float32]uintptr:
  13325. if v2, changed2 := fastpathTV.DecMapFloat32UintptrV(*v, true, d); changed2 {
  13326. *v = v2
  13327. }
  13328. case map[float32]int:
  13329. fastpathTV.DecMapFloat32IntV(v, false, d)
  13330. case *map[float32]int:
  13331. if v2, changed2 := fastpathTV.DecMapFloat32IntV(*v, true, d); changed2 {
  13332. *v = v2
  13333. }
  13334. case map[float32]int8:
  13335. fastpathTV.DecMapFloat32Int8V(v, false, d)
  13336. case *map[float32]int8:
  13337. if v2, changed2 := fastpathTV.DecMapFloat32Int8V(*v, true, d); changed2 {
  13338. *v = v2
  13339. }
  13340. case map[float32]int16:
  13341. fastpathTV.DecMapFloat32Int16V(v, false, d)
  13342. case *map[float32]int16:
  13343. if v2, changed2 := fastpathTV.DecMapFloat32Int16V(*v, true, d); changed2 {
  13344. *v = v2
  13345. }
  13346. case map[float32]int32:
  13347. fastpathTV.DecMapFloat32Int32V(v, false, d)
  13348. case *map[float32]int32:
  13349. if v2, changed2 := fastpathTV.DecMapFloat32Int32V(*v, true, d); changed2 {
  13350. *v = v2
  13351. }
  13352. case map[float32]int64:
  13353. fastpathTV.DecMapFloat32Int64V(v, false, d)
  13354. case *map[float32]int64:
  13355. if v2, changed2 := fastpathTV.DecMapFloat32Int64V(*v, true, d); changed2 {
  13356. *v = v2
  13357. }
  13358. case map[float32]float32:
  13359. fastpathTV.DecMapFloat32Float32V(v, false, d)
  13360. case *map[float32]float32:
  13361. if v2, changed2 := fastpathTV.DecMapFloat32Float32V(*v, true, d); changed2 {
  13362. *v = v2
  13363. }
  13364. case map[float32]float64:
  13365. fastpathTV.DecMapFloat32Float64V(v, false, d)
  13366. case *map[float32]float64:
  13367. if v2, changed2 := fastpathTV.DecMapFloat32Float64V(*v, true, d); changed2 {
  13368. *v = v2
  13369. }
  13370. case map[float32]bool:
  13371. fastpathTV.DecMapFloat32BoolV(v, false, d)
  13372. case *map[float32]bool:
  13373. if v2, changed2 := fastpathTV.DecMapFloat32BoolV(*v, true, d); changed2 {
  13374. *v = v2
  13375. }
  13376. case []float64:
  13377. fastpathTV.DecSliceFloat64V(v, false, d)
  13378. case *[]float64:
  13379. if v2, changed2 := fastpathTV.DecSliceFloat64V(*v, true, d); changed2 {
  13380. *v = v2
  13381. }
  13382. case map[float64]interface{}:
  13383. fastpathTV.DecMapFloat64IntfV(v, false, d)
  13384. case *map[float64]interface{}:
  13385. if v2, changed2 := fastpathTV.DecMapFloat64IntfV(*v, true, d); changed2 {
  13386. *v = v2
  13387. }
  13388. case map[float64]string:
  13389. fastpathTV.DecMapFloat64StringV(v, false, d)
  13390. case *map[float64]string:
  13391. if v2, changed2 := fastpathTV.DecMapFloat64StringV(*v, true, d); changed2 {
  13392. *v = v2
  13393. }
  13394. case map[float64]uint:
  13395. fastpathTV.DecMapFloat64UintV(v, false, d)
  13396. case *map[float64]uint:
  13397. if v2, changed2 := fastpathTV.DecMapFloat64UintV(*v, true, d); changed2 {
  13398. *v = v2
  13399. }
  13400. case map[float64]uint8:
  13401. fastpathTV.DecMapFloat64Uint8V(v, false, d)
  13402. case *map[float64]uint8:
  13403. if v2, changed2 := fastpathTV.DecMapFloat64Uint8V(*v, true, d); changed2 {
  13404. *v = v2
  13405. }
  13406. case map[float64]uint16:
  13407. fastpathTV.DecMapFloat64Uint16V(v, false, d)
  13408. case *map[float64]uint16:
  13409. if v2, changed2 := fastpathTV.DecMapFloat64Uint16V(*v, true, d); changed2 {
  13410. *v = v2
  13411. }
  13412. case map[float64]uint32:
  13413. fastpathTV.DecMapFloat64Uint32V(v, false, d)
  13414. case *map[float64]uint32:
  13415. if v2, changed2 := fastpathTV.DecMapFloat64Uint32V(*v, true, d); changed2 {
  13416. *v = v2
  13417. }
  13418. case map[float64]uint64:
  13419. fastpathTV.DecMapFloat64Uint64V(v, false, d)
  13420. case *map[float64]uint64:
  13421. if v2, changed2 := fastpathTV.DecMapFloat64Uint64V(*v, true, d); changed2 {
  13422. *v = v2
  13423. }
  13424. case map[float64]uintptr:
  13425. fastpathTV.DecMapFloat64UintptrV(v, false, d)
  13426. case *map[float64]uintptr:
  13427. if v2, changed2 := fastpathTV.DecMapFloat64UintptrV(*v, true, d); changed2 {
  13428. *v = v2
  13429. }
  13430. case map[float64]int:
  13431. fastpathTV.DecMapFloat64IntV(v, false, d)
  13432. case *map[float64]int:
  13433. if v2, changed2 := fastpathTV.DecMapFloat64IntV(*v, true, d); changed2 {
  13434. *v = v2
  13435. }
  13436. case map[float64]int8:
  13437. fastpathTV.DecMapFloat64Int8V(v, false, d)
  13438. case *map[float64]int8:
  13439. if v2, changed2 := fastpathTV.DecMapFloat64Int8V(*v, true, d); changed2 {
  13440. *v = v2
  13441. }
  13442. case map[float64]int16:
  13443. fastpathTV.DecMapFloat64Int16V(v, false, d)
  13444. case *map[float64]int16:
  13445. if v2, changed2 := fastpathTV.DecMapFloat64Int16V(*v, true, d); changed2 {
  13446. *v = v2
  13447. }
  13448. case map[float64]int32:
  13449. fastpathTV.DecMapFloat64Int32V(v, false, d)
  13450. case *map[float64]int32:
  13451. if v2, changed2 := fastpathTV.DecMapFloat64Int32V(*v, true, d); changed2 {
  13452. *v = v2
  13453. }
  13454. case map[float64]int64:
  13455. fastpathTV.DecMapFloat64Int64V(v, false, d)
  13456. case *map[float64]int64:
  13457. if v2, changed2 := fastpathTV.DecMapFloat64Int64V(*v, true, d); changed2 {
  13458. *v = v2
  13459. }
  13460. case map[float64]float32:
  13461. fastpathTV.DecMapFloat64Float32V(v, false, d)
  13462. case *map[float64]float32:
  13463. if v2, changed2 := fastpathTV.DecMapFloat64Float32V(*v, true, d); changed2 {
  13464. *v = v2
  13465. }
  13466. case map[float64]float64:
  13467. fastpathTV.DecMapFloat64Float64V(v, false, d)
  13468. case *map[float64]float64:
  13469. if v2, changed2 := fastpathTV.DecMapFloat64Float64V(*v, true, d); changed2 {
  13470. *v = v2
  13471. }
  13472. case map[float64]bool:
  13473. fastpathTV.DecMapFloat64BoolV(v, false, d)
  13474. case *map[float64]bool:
  13475. if v2, changed2 := fastpathTV.DecMapFloat64BoolV(*v, true, d); changed2 {
  13476. *v = v2
  13477. }
  13478. case []uint:
  13479. fastpathTV.DecSliceUintV(v, false, d)
  13480. case *[]uint:
  13481. if v2, changed2 := fastpathTV.DecSliceUintV(*v, true, d); changed2 {
  13482. *v = v2
  13483. }
  13484. case map[uint]interface{}:
  13485. fastpathTV.DecMapUintIntfV(v, false, d)
  13486. case *map[uint]interface{}:
  13487. if v2, changed2 := fastpathTV.DecMapUintIntfV(*v, true, d); changed2 {
  13488. *v = v2
  13489. }
  13490. case map[uint]string:
  13491. fastpathTV.DecMapUintStringV(v, false, d)
  13492. case *map[uint]string:
  13493. if v2, changed2 := fastpathTV.DecMapUintStringV(*v, true, d); changed2 {
  13494. *v = v2
  13495. }
  13496. case map[uint]uint:
  13497. fastpathTV.DecMapUintUintV(v, false, d)
  13498. case *map[uint]uint:
  13499. if v2, changed2 := fastpathTV.DecMapUintUintV(*v, true, d); changed2 {
  13500. *v = v2
  13501. }
  13502. case map[uint]uint8:
  13503. fastpathTV.DecMapUintUint8V(v, false, d)
  13504. case *map[uint]uint8:
  13505. if v2, changed2 := fastpathTV.DecMapUintUint8V(*v, true, d); changed2 {
  13506. *v = v2
  13507. }
  13508. case map[uint]uint16:
  13509. fastpathTV.DecMapUintUint16V(v, false, d)
  13510. case *map[uint]uint16:
  13511. if v2, changed2 := fastpathTV.DecMapUintUint16V(*v, true, d); changed2 {
  13512. *v = v2
  13513. }
  13514. case map[uint]uint32:
  13515. fastpathTV.DecMapUintUint32V(v, false, d)
  13516. case *map[uint]uint32:
  13517. if v2, changed2 := fastpathTV.DecMapUintUint32V(*v, true, d); changed2 {
  13518. *v = v2
  13519. }
  13520. case map[uint]uint64:
  13521. fastpathTV.DecMapUintUint64V(v, false, d)
  13522. case *map[uint]uint64:
  13523. if v2, changed2 := fastpathTV.DecMapUintUint64V(*v, true, d); changed2 {
  13524. *v = v2
  13525. }
  13526. case map[uint]uintptr:
  13527. fastpathTV.DecMapUintUintptrV(v, false, d)
  13528. case *map[uint]uintptr:
  13529. if v2, changed2 := fastpathTV.DecMapUintUintptrV(*v, true, d); changed2 {
  13530. *v = v2
  13531. }
  13532. case map[uint]int:
  13533. fastpathTV.DecMapUintIntV(v, false, d)
  13534. case *map[uint]int:
  13535. if v2, changed2 := fastpathTV.DecMapUintIntV(*v, true, d); changed2 {
  13536. *v = v2
  13537. }
  13538. case map[uint]int8:
  13539. fastpathTV.DecMapUintInt8V(v, false, d)
  13540. case *map[uint]int8:
  13541. if v2, changed2 := fastpathTV.DecMapUintInt8V(*v, true, d); changed2 {
  13542. *v = v2
  13543. }
  13544. case map[uint]int16:
  13545. fastpathTV.DecMapUintInt16V(v, false, d)
  13546. case *map[uint]int16:
  13547. if v2, changed2 := fastpathTV.DecMapUintInt16V(*v, true, d); changed2 {
  13548. *v = v2
  13549. }
  13550. case map[uint]int32:
  13551. fastpathTV.DecMapUintInt32V(v, false, d)
  13552. case *map[uint]int32:
  13553. if v2, changed2 := fastpathTV.DecMapUintInt32V(*v, true, d); changed2 {
  13554. *v = v2
  13555. }
  13556. case map[uint]int64:
  13557. fastpathTV.DecMapUintInt64V(v, false, d)
  13558. case *map[uint]int64:
  13559. if v2, changed2 := fastpathTV.DecMapUintInt64V(*v, true, d); changed2 {
  13560. *v = v2
  13561. }
  13562. case map[uint]float32:
  13563. fastpathTV.DecMapUintFloat32V(v, false, d)
  13564. case *map[uint]float32:
  13565. if v2, changed2 := fastpathTV.DecMapUintFloat32V(*v, true, d); changed2 {
  13566. *v = v2
  13567. }
  13568. case map[uint]float64:
  13569. fastpathTV.DecMapUintFloat64V(v, false, d)
  13570. case *map[uint]float64:
  13571. if v2, changed2 := fastpathTV.DecMapUintFloat64V(*v, true, d); changed2 {
  13572. *v = v2
  13573. }
  13574. case map[uint]bool:
  13575. fastpathTV.DecMapUintBoolV(v, false, d)
  13576. case *map[uint]bool:
  13577. if v2, changed2 := fastpathTV.DecMapUintBoolV(*v, true, d); changed2 {
  13578. *v = v2
  13579. }
  13580. case map[uint8]interface{}:
  13581. fastpathTV.DecMapUint8IntfV(v, false, d)
  13582. case *map[uint8]interface{}:
  13583. if v2, changed2 := fastpathTV.DecMapUint8IntfV(*v, true, d); changed2 {
  13584. *v = v2
  13585. }
  13586. case map[uint8]string:
  13587. fastpathTV.DecMapUint8StringV(v, false, d)
  13588. case *map[uint8]string:
  13589. if v2, changed2 := fastpathTV.DecMapUint8StringV(*v, true, d); changed2 {
  13590. *v = v2
  13591. }
  13592. case map[uint8]uint:
  13593. fastpathTV.DecMapUint8UintV(v, false, d)
  13594. case *map[uint8]uint:
  13595. if v2, changed2 := fastpathTV.DecMapUint8UintV(*v, true, d); changed2 {
  13596. *v = v2
  13597. }
  13598. case map[uint8]uint8:
  13599. fastpathTV.DecMapUint8Uint8V(v, false, d)
  13600. case *map[uint8]uint8:
  13601. if v2, changed2 := fastpathTV.DecMapUint8Uint8V(*v, true, d); changed2 {
  13602. *v = v2
  13603. }
  13604. case map[uint8]uint16:
  13605. fastpathTV.DecMapUint8Uint16V(v, false, d)
  13606. case *map[uint8]uint16:
  13607. if v2, changed2 := fastpathTV.DecMapUint8Uint16V(*v, true, d); changed2 {
  13608. *v = v2
  13609. }
  13610. case map[uint8]uint32:
  13611. fastpathTV.DecMapUint8Uint32V(v, false, d)
  13612. case *map[uint8]uint32:
  13613. if v2, changed2 := fastpathTV.DecMapUint8Uint32V(*v, true, d); changed2 {
  13614. *v = v2
  13615. }
  13616. case map[uint8]uint64:
  13617. fastpathTV.DecMapUint8Uint64V(v, false, d)
  13618. case *map[uint8]uint64:
  13619. if v2, changed2 := fastpathTV.DecMapUint8Uint64V(*v, true, d); changed2 {
  13620. *v = v2
  13621. }
  13622. case map[uint8]uintptr:
  13623. fastpathTV.DecMapUint8UintptrV(v, false, d)
  13624. case *map[uint8]uintptr:
  13625. if v2, changed2 := fastpathTV.DecMapUint8UintptrV(*v, true, d); changed2 {
  13626. *v = v2
  13627. }
  13628. case map[uint8]int:
  13629. fastpathTV.DecMapUint8IntV(v, false, d)
  13630. case *map[uint8]int:
  13631. if v2, changed2 := fastpathTV.DecMapUint8IntV(*v, true, d); changed2 {
  13632. *v = v2
  13633. }
  13634. case map[uint8]int8:
  13635. fastpathTV.DecMapUint8Int8V(v, false, d)
  13636. case *map[uint8]int8:
  13637. if v2, changed2 := fastpathTV.DecMapUint8Int8V(*v, true, d); changed2 {
  13638. *v = v2
  13639. }
  13640. case map[uint8]int16:
  13641. fastpathTV.DecMapUint8Int16V(v, false, d)
  13642. case *map[uint8]int16:
  13643. if v2, changed2 := fastpathTV.DecMapUint8Int16V(*v, true, d); changed2 {
  13644. *v = v2
  13645. }
  13646. case map[uint8]int32:
  13647. fastpathTV.DecMapUint8Int32V(v, false, d)
  13648. case *map[uint8]int32:
  13649. if v2, changed2 := fastpathTV.DecMapUint8Int32V(*v, true, d); changed2 {
  13650. *v = v2
  13651. }
  13652. case map[uint8]int64:
  13653. fastpathTV.DecMapUint8Int64V(v, false, d)
  13654. case *map[uint8]int64:
  13655. if v2, changed2 := fastpathTV.DecMapUint8Int64V(*v, true, d); changed2 {
  13656. *v = v2
  13657. }
  13658. case map[uint8]float32:
  13659. fastpathTV.DecMapUint8Float32V(v, false, d)
  13660. case *map[uint8]float32:
  13661. if v2, changed2 := fastpathTV.DecMapUint8Float32V(*v, true, d); changed2 {
  13662. *v = v2
  13663. }
  13664. case map[uint8]float64:
  13665. fastpathTV.DecMapUint8Float64V(v, false, d)
  13666. case *map[uint8]float64:
  13667. if v2, changed2 := fastpathTV.DecMapUint8Float64V(*v, true, d); changed2 {
  13668. *v = v2
  13669. }
  13670. case map[uint8]bool:
  13671. fastpathTV.DecMapUint8BoolV(v, false, d)
  13672. case *map[uint8]bool:
  13673. if v2, changed2 := fastpathTV.DecMapUint8BoolV(*v, true, d); changed2 {
  13674. *v = v2
  13675. }
  13676. case []uint16:
  13677. fastpathTV.DecSliceUint16V(v, false, d)
  13678. case *[]uint16:
  13679. if v2, changed2 := fastpathTV.DecSliceUint16V(*v, true, d); changed2 {
  13680. *v = v2
  13681. }
  13682. case map[uint16]interface{}:
  13683. fastpathTV.DecMapUint16IntfV(v, false, d)
  13684. case *map[uint16]interface{}:
  13685. if v2, changed2 := fastpathTV.DecMapUint16IntfV(*v, true, d); changed2 {
  13686. *v = v2
  13687. }
  13688. case map[uint16]string:
  13689. fastpathTV.DecMapUint16StringV(v, false, d)
  13690. case *map[uint16]string:
  13691. if v2, changed2 := fastpathTV.DecMapUint16StringV(*v, true, d); changed2 {
  13692. *v = v2
  13693. }
  13694. case map[uint16]uint:
  13695. fastpathTV.DecMapUint16UintV(v, false, d)
  13696. case *map[uint16]uint:
  13697. if v2, changed2 := fastpathTV.DecMapUint16UintV(*v, true, d); changed2 {
  13698. *v = v2
  13699. }
  13700. case map[uint16]uint8:
  13701. fastpathTV.DecMapUint16Uint8V(v, false, d)
  13702. case *map[uint16]uint8:
  13703. if v2, changed2 := fastpathTV.DecMapUint16Uint8V(*v, true, d); changed2 {
  13704. *v = v2
  13705. }
  13706. case map[uint16]uint16:
  13707. fastpathTV.DecMapUint16Uint16V(v, false, d)
  13708. case *map[uint16]uint16:
  13709. if v2, changed2 := fastpathTV.DecMapUint16Uint16V(*v, true, d); changed2 {
  13710. *v = v2
  13711. }
  13712. case map[uint16]uint32:
  13713. fastpathTV.DecMapUint16Uint32V(v, false, d)
  13714. case *map[uint16]uint32:
  13715. if v2, changed2 := fastpathTV.DecMapUint16Uint32V(*v, true, d); changed2 {
  13716. *v = v2
  13717. }
  13718. case map[uint16]uint64:
  13719. fastpathTV.DecMapUint16Uint64V(v, false, d)
  13720. case *map[uint16]uint64:
  13721. if v2, changed2 := fastpathTV.DecMapUint16Uint64V(*v, true, d); changed2 {
  13722. *v = v2
  13723. }
  13724. case map[uint16]uintptr:
  13725. fastpathTV.DecMapUint16UintptrV(v, false, d)
  13726. case *map[uint16]uintptr:
  13727. if v2, changed2 := fastpathTV.DecMapUint16UintptrV(*v, true, d); changed2 {
  13728. *v = v2
  13729. }
  13730. case map[uint16]int:
  13731. fastpathTV.DecMapUint16IntV(v, false, d)
  13732. case *map[uint16]int:
  13733. if v2, changed2 := fastpathTV.DecMapUint16IntV(*v, true, d); changed2 {
  13734. *v = v2
  13735. }
  13736. case map[uint16]int8:
  13737. fastpathTV.DecMapUint16Int8V(v, false, d)
  13738. case *map[uint16]int8:
  13739. if v2, changed2 := fastpathTV.DecMapUint16Int8V(*v, true, d); changed2 {
  13740. *v = v2
  13741. }
  13742. case map[uint16]int16:
  13743. fastpathTV.DecMapUint16Int16V(v, false, d)
  13744. case *map[uint16]int16:
  13745. if v2, changed2 := fastpathTV.DecMapUint16Int16V(*v, true, d); changed2 {
  13746. *v = v2
  13747. }
  13748. case map[uint16]int32:
  13749. fastpathTV.DecMapUint16Int32V(v, false, d)
  13750. case *map[uint16]int32:
  13751. if v2, changed2 := fastpathTV.DecMapUint16Int32V(*v, true, d); changed2 {
  13752. *v = v2
  13753. }
  13754. case map[uint16]int64:
  13755. fastpathTV.DecMapUint16Int64V(v, false, d)
  13756. case *map[uint16]int64:
  13757. if v2, changed2 := fastpathTV.DecMapUint16Int64V(*v, true, d); changed2 {
  13758. *v = v2
  13759. }
  13760. case map[uint16]float32:
  13761. fastpathTV.DecMapUint16Float32V(v, false, d)
  13762. case *map[uint16]float32:
  13763. if v2, changed2 := fastpathTV.DecMapUint16Float32V(*v, true, d); changed2 {
  13764. *v = v2
  13765. }
  13766. case map[uint16]float64:
  13767. fastpathTV.DecMapUint16Float64V(v, false, d)
  13768. case *map[uint16]float64:
  13769. if v2, changed2 := fastpathTV.DecMapUint16Float64V(*v, true, d); changed2 {
  13770. *v = v2
  13771. }
  13772. case map[uint16]bool:
  13773. fastpathTV.DecMapUint16BoolV(v, false, d)
  13774. case *map[uint16]bool:
  13775. if v2, changed2 := fastpathTV.DecMapUint16BoolV(*v, true, d); changed2 {
  13776. *v = v2
  13777. }
  13778. case []uint32:
  13779. fastpathTV.DecSliceUint32V(v, false, d)
  13780. case *[]uint32:
  13781. if v2, changed2 := fastpathTV.DecSliceUint32V(*v, true, d); changed2 {
  13782. *v = v2
  13783. }
  13784. case map[uint32]interface{}:
  13785. fastpathTV.DecMapUint32IntfV(v, false, d)
  13786. case *map[uint32]interface{}:
  13787. if v2, changed2 := fastpathTV.DecMapUint32IntfV(*v, true, d); changed2 {
  13788. *v = v2
  13789. }
  13790. case map[uint32]string:
  13791. fastpathTV.DecMapUint32StringV(v, false, d)
  13792. case *map[uint32]string:
  13793. if v2, changed2 := fastpathTV.DecMapUint32StringV(*v, true, d); changed2 {
  13794. *v = v2
  13795. }
  13796. case map[uint32]uint:
  13797. fastpathTV.DecMapUint32UintV(v, false, d)
  13798. case *map[uint32]uint:
  13799. if v2, changed2 := fastpathTV.DecMapUint32UintV(*v, true, d); changed2 {
  13800. *v = v2
  13801. }
  13802. case map[uint32]uint8:
  13803. fastpathTV.DecMapUint32Uint8V(v, false, d)
  13804. case *map[uint32]uint8:
  13805. if v2, changed2 := fastpathTV.DecMapUint32Uint8V(*v, true, d); changed2 {
  13806. *v = v2
  13807. }
  13808. case map[uint32]uint16:
  13809. fastpathTV.DecMapUint32Uint16V(v, false, d)
  13810. case *map[uint32]uint16:
  13811. if v2, changed2 := fastpathTV.DecMapUint32Uint16V(*v, true, d); changed2 {
  13812. *v = v2
  13813. }
  13814. case map[uint32]uint32:
  13815. fastpathTV.DecMapUint32Uint32V(v, false, d)
  13816. case *map[uint32]uint32:
  13817. if v2, changed2 := fastpathTV.DecMapUint32Uint32V(*v, true, d); changed2 {
  13818. *v = v2
  13819. }
  13820. case map[uint32]uint64:
  13821. fastpathTV.DecMapUint32Uint64V(v, false, d)
  13822. case *map[uint32]uint64:
  13823. if v2, changed2 := fastpathTV.DecMapUint32Uint64V(*v, true, d); changed2 {
  13824. *v = v2
  13825. }
  13826. case map[uint32]uintptr:
  13827. fastpathTV.DecMapUint32UintptrV(v, false, d)
  13828. case *map[uint32]uintptr:
  13829. if v2, changed2 := fastpathTV.DecMapUint32UintptrV(*v, true, d); changed2 {
  13830. *v = v2
  13831. }
  13832. case map[uint32]int:
  13833. fastpathTV.DecMapUint32IntV(v, false, d)
  13834. case *map[uint32]int:
  13835. if v2, changed2 := fastpathTV.DecMapUint32IntV(*v, true, d); changed2 {
  13836. *v = v2
  13837. }
  13838. case map[uint32]int8:
  13839. fastpathTV.DecMapUint32Int8V(v, false, d)
  13840. case *map[uint32]int8:
  13841. if v2, changed2 := fastpathTV.DecMapUint32Int8V(*v, true, d); changed2 {
  13842. *v = v2
  13843. }
  13844. case map[uint32]int16:
  13845. fastpathTV.DecMapUint32Int16V(v, false, d)
  13846. case *map[uint32]int16:
  13847. if v2, changed2 := fastpathTV.DecMapUint32Int16V(*v, true, d); changed2 {
  13848. *v = v2
  13849. }
  13850. case map[uint32]int32:
  13851. fastpathTV.DecMapUint32Int32V(v, false, d)
  13852. case *map[uint32]int32:
  13853. if v2, changed2 := fastpathTV.DecMapUint32Int32V(*v, true, d); changed2 {
  13854. *v = v2
  13855. }
  13856. case map[uint32]int64:
  13857. fastpathTV.DecMapUint32Int64V(v, false, d)
  13858. case *map[uint32]int64:
  13859. if v2, changed2 := fastpathTV.DecMapUint32Int64V(*v, true, d); changed2 {
  13860. *v = v2
  13861. }
  13862. case map[uint32]float32:
  13863. fastpathTV.DecMapUint32Float32V(v, false, d)
  13864. case *map[uint32]float32:
  13865. if v2, changed2 := fastpathTV.DecMapUint32Float32V(*v, true, d); changed2 {
  13866. *v = v2
  13867. }
  13868. case map[uint32]float64:
  13869. fastpathTV.DecMapUint32Float64V(v, false, d)
  13870. case *map[uint32]float64:
  13871. if v2, changed2 := fastpathTV.DecMapUint32Float64V(*v, true, d); changed2 {
  13872. *v = v2
  13873. }
  13874. case map[uint32]bool:
  13875. fastpathTV.DecMapUint32BoolV(v, false, d)
  13876. case *map[uint32]bool:
  13877. if v2, changed2 := fastpathTV.DecMapUint32BoolV(*v, true, d); changed2 {
  13878. *v = v2
  13879. }
  13880. case []uint64:
  13881. fastpathTV.DecSliceUint64V(v, false, d)
  13882. case *[]uint64:
  13883. if v2, changed2 := fastpathTV.DecSliceUint64V(*v, true, d); changed2 {
  13884. *v = v2
  13885. }
  13886. case map[uint64]interface{}:
  13887. fastpathTV.DecMapUint64IntfV(v, false, d)
  13888. case *map[uint64]interface{}:
  13889. if v2, changed2 := fastpathTV.DecMapUint64IntfV(*v, true, d); changed2 {
  13890. *v = v2
  13891. }
  13892. case map[uint64]string:
  13893. fastpathTV.DecMapUint64StringV(v, false, d)
  13894. case *map[uint64]string:
  13895. if v2, changed2 := fastpathTV.DecMapUint64StringV(*v, true, d); changed2 {
  13896. *v = v2
  13897. }
  13898. case map[uint64]uint:
  13899. fastpathTV.DecMapUint64UintV(v, false, d)
  13900. case *map[uint64]uint:
  13901. if v2, changed2 := fastpathTV.DecMapUint64UintV(*v, true, d); changed2 {
  13902. *v = v2
  13903. }
  13904. case map[uint64]uint8:
  13905. fastpathTV.DecMapUint64Uint8V(v, false, d)
  13906. case *map[uint64]uint8:
  13907. if v2, changed2 := fastpathTV.DecMapUint64Uint8V(*v, true, d); changed2 {
  13908. *v = v2
  13909. }
  13910. case map[uint64]uint16:
  13911. fastpathTV.DecMapUint64Uint16V(v, false, d)
  13912. case *map[uint64]uint16:
  13913. if v2, changed2 := fastpathTV.DecMapUint64Uint16V(*v, true, d); changed2 {
  13914. *v = v2
  13915. }
  13916. case map[uint64]uint32:
  13917. fastpathTV.DecMapUint64Uint32V(v, false, d)
  13918. case *map[uint64]uint32:
  13919. if v2, changed2 := fastpathTV.DecMapUint64Uint32V(*v, true, d); changed2 {
  13920. *v = v2
  13921. }
  13922. case map[uint64]uint64:
  13923. fastpathTV.DecMapUint64Uint64V(v, false, d)
  13924. case *map[uint64]uint64:
  13925. if v2, changed2 := fastpathTV.DecMapUint64Uint64V(*v, true, d); changed2 {
  13926. *v = v2
  13927. }
  13928. case map[uint64]uintptr:
  13929. fastpathTV.DecMapUint64UintptrV(v, false, d)
  13930. case *map[uint64]uintptr:
  13931. if v2, changed2 := fastpathTV.DecMapUint64UintptrV(*v, true, d); changed2 {
  13932. *v = v2
  13933. }
  13934. case map[uint64]int:
  13935. fastpathTV.DecMapUint64IntV(v, false, d)
  13936. case *map[uint64]int:
  13937. if v2, changed2 := fastpathTV.DecMapUint64IntV(*v, true, d); changed2 {
  13938. *v = v2
  13939. }
  13940. case map[uint64]int8:
  13941. fastpathTV.DecMapUint64Int8V(v, false, d)
  13942. case *map[uint64]int8:
  13943. if v2, changed2 := fastpathTV.DecMapUint64Int8V(*v, true, d); changed2 {
  13944. *v = v2
  13945. }
  13946. case map[uint64]int16:
  13947. fastpathTV.DecMapUint64Int16V(v, false, d)
  13948. case *map[uint64]int16:
  13949. if v2, changed2 := fastpathTV.DecMapUint64Int16V(*v, true, d); changed2 {
  13950. *v = v2
  13951. }
  13952. case map[uint64]int32:
  13953. fastpathTV.DecMapUint64Int32V(v, false, d)
  13954. case *map[uint64]int32:
  13955. if v2, changed2 := fastpathTV.DecMapUint64Int32V(*v, true, d); changed2 {
  13956. *v = v2
  13957. }
  13958. case map[uint64]int64:
  13959. fastpathTV.DecMapUint64Int64V(v, false, d)
  13960. case *map[uint64]int64:
  13961. if v2, changed2 := fastpathTV.DecMapUint64Int64V(*v, true, d); changed2 {
  13962. *v = v2
  13963. }
  13964. case map[uint64]float32:
  13965. fastpathTV.DecMapUint64Float32V(v, false, d)
  13966. case *map[uint64]float32:
  13967. if v2, changed2 := fastpathTV.DecMapUint64Float32V(*v, true, d); changed2 {
  13968. *v = v2
  13969. }
  13970. case map[uint64]float64:
  13971. fastpathTV.DecMapUint64Float64V(v, false, d)
  13972. case *map[uint64]float64:
  13973. if v2, changed2 := fastpathTV.DecMapUint64Float64V(*v, true, d); changed2 {
  13974. *v = v2
  13975. }
  13976. case map[uint64]bool:
  13977. fastpathTV.DecMapUint64BoolV(v, false, d)
  13978. case *map[uint64]bool:
  13979. if v2, changed2 := fastpathTV.DecMapUint64BoolV(*v, true, d); changed2 {
  13980. *v = v2
  13981. }
  13982. case []uintptr:
  13983. fastpathTV.DecSliceUintptrV(v, false, d)
  13984. case *[]uintptr:
  13985. if v2, changed2 := fastpathTV.DecSliceUintptrV(*v, true, d); changed2 {
  13986. *v = v2
  13987. }
  13988. case map[uintptr]interface{}:
  13989. fastpathTV.DecMapUintptrIntfV(v, false, d)
  13990. case *map[uintptr]interface{}:
  13991. if v2, changed2 := fastpathTV.DecMapUintptrIntfV(*v, true, d); changed2 {
  13992. *v = v2
  13993. }
  13994. case map[uintptr]string:
  13995. fastpathTV.DecMapUintptrStringV(v, false, d)
  13996. case *map[uintptr]string:
  13997. if v2, changed2 := fastpathTV.DecMapUintptrStringV(*v, true, d); changed2 {
  13998. *v = v2
  13999. }
  14000. case map[uintptr]uint:
  14001. fastpathTV.DecMapUintptrUintV(v, false, d)
  14002. case *map[uintptr]uint:
  14003. if v2, changed2 := fastpathTV.DecMapUintptrUintV(*v, true, d); changed2 {
  14004. *v = v2
  14005. }
  14006. case map[uintptr]uint8:
  14007. fastpathTV.DecMapUintptrUint8V(v, false, d)
  14008. case *map[uintptr]uint8:
  14009. if v2, changed2 := fastpathTV.DecMapUintptrUint8V(*v, true, d); changed2 {
  14010. *v = v2
  14011. }
  14012. case map[uintptr]uint16:
  14013. fastpathTV.DecMapUintptrUint16V(v, false, d)
  14014. case *map[uintptr]uint16:
  14015. if v2, changed2 := fastpathTV.DecMapUintptrUint16V(*v, true, d); changed2 {
  14016. *v = v2
  14017. }
  14018. case map[uintptr]uint32:
  14019. fastpathTV.DecMapUintptrUint32V(v, false, d)
  14020. case *map[uintptr]uint32:
  14021. if v2, changed2 := fastpathTV.DecMapUintptrUint32V(*v, true, d); changed2 {
  14022. *v = v2
  14023. }
  14024. case map[uintptr]uint64:
  14025. fastpathTV.DecMapUintptrUint64V(v, false, d)
  14026. case *map[uintptr]uint64:
  14027. if v2, changed2 := fastpathTV.DecMapUintptrUint64V(*v, true, d); changed2 {
  14028. *v = v2
  14029. }
  14030. case map[uintptr]uintptr:
  14031. fastpathTV.DecMapUintptrUintptrV(v, false, d)
  14032. case *map[uintptr]uintptr:
  14033. if v2, changed2 := fastpathTV.DecMapUintptrUintptrV(*v, true, d); changed2 {
  14034. *v = v2
  14035. }
  14036. case map[uintptr]int:
  14037. fastpathTV.DecMapUintptrIntV(v, false, d)
  14038. case *map[uintptr]int:
  14039. if v2, changed2 := fastpathTV.DecMapUintptrIntV(*v, true, d); changed2 {
  14040. *v = v2
  14041. }
  14042. case map[uintptr]int8:
  14043. fastpathTV.DecMapUintptrInt8V(v, false, d)
  14044. case *map[uintptr]int8:
  14045. if v2, changed2 := fastpathTV.DecMapUintptrInt8V(*v, true, d); changed2 {
  14046. *v = v2
  14047. }
  14048. case map[uintptr]int16:
  14049. fastpathTV.DecMapUintptrInt16V(v, false, d)
  14050. case *map[uintptr]int16:
  14051. if v2, changed2 := fastpathTV.DecMapUintptrInt16V(*v, true, d); changed2 {
  14052. *v = v2
  14053. }
  14054. case map[uintptr]int32:
  14055. fastpathTV.DecMapUintptrInt32V(v, false, d)
  14056. case *map[uintptr]int32:
  14057. if v2, changed2 := fastpathTV.DecMapUintptrInt32V(*v, true, d); changed2 {
  14058. *v = v2
  14059. }
  14060. case map[uintptr]int64:
  14061. fastpathTV.DecMapUintptrInt64V(v, false, d)
  14062. case *map[uintptr]int64:
  14063. if v2, changed2 := fastpathTV.DecMapUintptrInt64V(*v, true, d); changed2 {
  14064. *v = v2
  14065. }
  14066. case map[uintptr]float32:
  14067. fastpathTV.DecMapUintptrFloat32V(v, false, d)
  14068. case *map[uintptr]float32:
  14069. if v2, changed2 := fastpathTV.DecMapUintptrFloat32V(*v, true, d); changed2 {
  14070. *v = v2
  14071. }
  14072. case map[uintptr]float64:
  14073. fastpathTV.DecMapUintptrFloat64V(v, false, d)
  14074. case *map[uintptr]float64:
  14075. if v2, changed2 := fastpathTV.DecMapUintptrFloat64V(*v, true, d); changed2 {
  14076. *v = v2
  14077. }
  14078. case map[uintptr]bool:
  14079. fastpathTV.DecMapUintptrBoolV(v, false, d)
  14080. case *map[uintptr]bool:
  14081. if v2, changed2 := fastpathTV.DecMapUintptrBoolV(*v, true, d); changed2 {
  14082. *v = v2
  14083. }
  14084. case []int:
  14085. fastpathTV.DecSliceIntV(v, false, d)
  14086. case *[]int:
  14087. if v2, changed2 := fastpathTV.DecSliceIntV(*v, true, d); changed2 {
  14088. *v = v2
  14089. }
  14090. case map[int]interface{}:
  14091. fastpathTV.DecMapIntIntfV(v, false, d)
  14092. case *map[int]interface{}:
  14093. if v2, changed2 := fastpathTV.DecMapIntIntfV(*v, true, d); changed2 {
  14094. *v = v2
  14095. }
  14096. case map[int]string:
  14097. fastpathTV.DecMapIntStringV(v, false, d)
  14098. case *map[int]string:
  14099. if v2, changed2 := fastpathTV.DecMapIntStringV(*v, true, d); changed2 {
  14100. *v = v2
  14101. }
  14102. case map[int]uint:
  14103. fastpathTV.DecMapIntUintV(v, false, d)
  14104. case *map[int]uint:
  14105. if v2, changed2 := fastpathTV.DecMapIntUintV(*v, true, d); changed2 {
  14106. *v = v2
  14107. }
  14108. case map[int]uint8:
  14109. fastpathTV.DecMapIntUint8V(v, false, d)
  14110. case *map[int]uint8:
  14111. if v2, changed2 := fastpathTV.DecMapIntUint8V(*v, true, d); changed2 {
  14112. *v = v2
  14113. }
  14114. case map[int]uint16:
  14115. fastpathTV.DecMapIntUint16V(v, false, d)
  14116. case *map[int]uint16:
  14117. if v2, changed2 := fastpathTV.DecMapIntUint16V(*v, true, d); changed2 {
  14118. *v = v2
  14119. }
  14120. case map[int]uint32:
  14121. fastpathTV.DecMapIntUint32V(v, false, d)
  14122. case *map[int]uint32:
  14123. if v2, changed2 := fastpathTV.DecMapIntUint32V(*v, true, d); changed2 {
  14124. *v = v2
  14125. }
  14126. case map[int]uint64:
  14127. fastpathTV.DecMapIntUint64V(v, false, d)
  14128. case *map[int]uint64:
  14129. if v2, changed2 := fastpathTV.DecMapIntUint64V(*v, true, d); changed2 {
  14130. *v = v2
  14131. }
  14132. case map[int]uintptr:
  14133. fastpathTV.DecMapIntUintptrV(v, false, d)
  14134. case *map[int]uintptr:
  14135. if v2, changed2 := fastpathTV.DecMapIntUintptrV(*v, true, d); changed2 {
  14136. *v = v2
  14137. }
  14138. case map[int]int:
  14139. fastpathTV.DecMapIntIntV(v, false, d)
  14140. case *map[int]int:
  14141. if v2, changed2 := fastpathTV.DecMapIntIntV(*v, true, d); changed2 {
  14142. *v = v2
  14143. }
  14144. case map[int]int8:
  14145. fastpathTV.DecMapIntInt8V(v, false, d)
  14146. case *map[int]int8:
  14147. if v2, changed2 := fastpathTV.DecMapIntInt8V(*v, true, d); changed2 {
  14148. *v = v2
  14149. }
  14150. case map[int]int16:
  14151. fastpathTV.DecMapIntInt16V(v, false, d)
  14152. case *map[int]int16:
  14153. if v2, changed2 := fastpathTV.DecMapIntInt16V(*v, true, d); changed2 {
  14154. *v = v2
  14155. }
  14156. case map[int]int32:
  14157. fastpathTV.DecMapIntInt32V(v, false, d)
  14158. case *map[int]int32:
  14159. if v2, changed2 := fastpathTV.DecMapIntInt32V(*v, true, d); changed2 {
  14160. *v = v2
  14161. }
  14162. case map[int]int64:
  14163. fastpathTV.DecMapIntInt64V(v, false, d)
  14164. case *map[int]int64:
  14165. if v2, changed2 := fastpathTV.DecMapIntInt64V(*v, true, d); changed2 {
  14166. *v = v2
  14167. }
  14168. case map[int]float32:
  14169. fastpathTV.DecMapIntFloat32V(v, false, d)
  14170. case *map[int]float32:
  14171. if v2, changed2 := fastpathTV.DecMapIntFloat32V(*v, true, d); changed2 {
  14172. *v = v2
  14173. }
  14174. case map[int]float64:
  14175. fastpathTV.DecMapIntFloat64V(v, false, d)
  14176. case *map[int]float64:
  14177. if v2, changed2 := fastpathTV.DecMapIntFloat64V(*v, true, d); changed2 {
  14178. *v = v2
  14179. }
  14180. case map[int]bool:
  14181. fastpathTV.DecMapIntBoolV(v, false, d)
  14182. case *map[int]bool:
  14183. if v2, changed2 := fastpathTV.DecMapIntBoolV(*v, true, d); changed2 {
  14184. *v = v2
  14185. }
  14186. case []int8:
  14187. fastpathTV.DecSliceInt8V(v, false, d)
  14188. case *[]int8:
  14189. if v2, changed2 := fastpathTV.DecSliceInt8V(*v, true, d); changed2 {
  14190. *v = v2
  14191. }
  14192. case map[int8]interface{}:
  14193. fastpathTV.DecMapInt8IntfV(v, false, d)
  14194. case *map[int8]interface{}:
  14195. if v2, changed2 := fastpathTV.DecMapInt8IntfV(*v, true, d); changed2 {
  14196. *v = v2
  14197. }
  14198. case map[int8]string:
  14199. fastpathTV.DecMapInt8StringV(v, false, d)
  14200. case *map[int8]string:
  14201. if v2, changed2 := fastpathTV.DecMapInt8StringV(*v, true, d); changed2 {
  14202. *v = v2
  14203. }
  14204. case map[int8]uint:
  14205. fastpathTV.DecMapInt8UintV(v, false, d)
  14206. case *map[int8]uint:
  14207. if v2, changed2 := fastpathTV.DecMapInt8UintV(*v, true, d); changed2 {
  14208. *v = v2
  14209. }
  14210. case map[int8]uint8:
  14211. fastpathTV.DecMapInt8Uint8V(v, false, d)
  14212. case *map[int8]uint8:
  14213. if v2, changed2 := fastpathTV.DecMapInt8Uint8V(*v, true, d); changed2 {
  14214. *v = v2
  14215. }
  14216. case map[int8]uint16:
  14217. fastpathTV.DecMapInt8Uint16V(v, false, d)
  14218. case *map[int8]uint16:
  14219. if v2, changed2 := fastpathTV.DecMapInt8Uint16V(*v, true, d); changed2 {
  14220. *v = v2
  14221. }
  14222. case map[int8]uint32:
  14223. fastpathTV.DecMapInt8Uint32V(v, false, d)
  14224. case *map[int8]uint32:
  14225. if v2, changed2 := fastpathTV.DecMapInt8Uint32V(*v, true, d); changed2 {
  14226. *v = v2
  14227. }
  14228. case map[int8]uint64:
  14229. fastpathTV.DecMapInt8Uint64V(v, false, d)
  14230. case *map[int8]uint64:
  14231. if v2, changed2 := fastpathTV.DecMapInt8Uint64V(*v, true, d); changed2 {
  14232. *v = v2
  14233. }
  14234. case map[int8]uintptr:
  14235. fastpathTV.DecMapInt8UintptrV(v, false, d)
  14236. case *map[int8]uintptr:
  14237. if v2, changed2 := fastpathTV.DecMapInt8UintptrV(*v, true, d); changed2 {
  14238. *v = v2
  14239. }
  14240. case map[int8]int:
  14241. fastpathTV.DecMapInt8IntV(v, false, d)
  14242. case *map[int8]int:
  14243. if v2, changed2 := fastpathTV.DecMapInt8IntV(*v, true, d); changed2 {
  14244. *v = v2
  14245. }
  14246. case map[int8]int8:
  14247. fastpathTV.DecMapInt8Int8V(v, false, d)
  14248. case *map[int8]int8:
  14249. if v2, changed2 := fastpathTV.DecMapInt8Int8V(*v, true, d); changed2 {
  14250. *v = v2
  14251. }
  14252. case map[int8]int16:
  14253. fastpathTV.DecMapInt8Int16V(v, false, d)
  14254. case *map[int8]int16:
  14255. if v2, changed2 := fastpathTV.DecMapInt8Int16V(*v, true, d); changed2 {
  14256. *v = v2
  14257. }
  14258. case map[int8]int32:
  14259. fastpathTV.DecMapInt8Int32V(v, false, d)
  14260. case *map[int8]int32:
  14261. if v2, changed2 := fastpathTV.DecMapInt8Int32V(*v, true, d); changed2 {
  14262. *v = v2
  14263. }
  14264. case map[int8]int64:
  14265. fastpathTV.DecMapInt8Int64V(v, false, d)
  14266. case *map[int8]int64:
  14267. if v2, changed2 := fastpathTV.DecMapInt8Int64V(*v, true, d); changed2 {
  14268. *v = v2
  14269. }
  14270. case map[int8]float32:
  14271. fastpathTV.DecMapInt8Float32V(v, false, d)
  14272. case *map[int8]float32:
  14273. if v2, changed2 := fastpathTV.DecMapInt8Float32V(*v, true, d); changed2 {
  14274. *v = v2
  14275. }
  14276. case map[int8]float64:
  14277. fastpathTV.DecMapInt8Float64V(v, false, d)
  14278. case *map[int8]float64:
  14279. if v2, changed2 := fastpathTV.DecMapInt8Float64V(*v, true, d); changed2 {
  14280. *v = v2
  14281. }
  14282. case map[int8]bool:
  14283. fastpathTV.DecMapInt8BoolV(v, false, d)
  14284. case *map[int8]bool:
  14285. if v2, changed2 := fastpathTV.DecMapInt8BoolV(*v, true, d); changed2 {
  14286. *v = v2
  14287. }
  14288. case []int16:
  14289. fastpathTV.DecSliceInt16V(v, false, d)
  14290. case *[]int16:
  14291. if v2, changed2 := fastpathTV.DecSliceInt16V(*v, true, d); changed2 {
  14292. *v = v2
  14293. }
  14294. case map[int16]interface{}:
  14295. fastpathTV.DecMapInt16IntfV(v, false, d)
  14296. case *map[int16]interface{}:
  14297. if v2, changed2 := fastpathTV.DecMapInt16IntfV(*v, true, d); changed2 {
  14298. *v = v2
  14299. }
  14300. case map[int16]string:
  14301. fastpathTV.DecMapInt16StringV(v, false, d)
  14302. case *map[int16]string:
  14303. if v2, changed2 := fastpathTV.DecMapInt16StringV(*v, true, d); changed2 {
  14304. *v = v2
  14305. }
  14306. case map[int16]uint:
  14307. fastpathTV.DecMapInt16UintV(v, false, d)
  14308. case *map[int16]uint:
  14309. if v2, changed2 := fastpathTV.DecMapInt16UintV(*v, true, d); changed2 {
  14310. *v = v2
  14311. }
  14312. case map[int16]uint8:
  14313. fastpathTV.DecMapInt16Uint8V(v, false, d)
  14314. case *map[int16]uint8:
  14315. if v2, changed2 := fastpathTV.DecMapInt16Uint8V(*v, true, d); changed2 {
  14316. *v = v2
  14317. }
  14318. case map[int16]uint16:
  14319. fastpathTV.DecMapInt16Uint16V(v, false, d)
  14320. case *map[int16]uint16:
  14321. if v2, changed2 := fastpathTV.DecMapInt16Uint16V(*v, true, d); changed2 {
  14322. *v = v2
  14323. }
  14324. case map[int16]uint32:
  14325. fastpathTV.DecMapInt16Uint32V(v, false, d)
  14326. case *map[int16]uint32:
  14327. if v2, changed2 := fastpathTV.DecMapInt16Uint32V(*v, true, d); changed2 {
  14328. *v = v2
  14329. }
  14330. case map[int16]uint64:
  14331. fastpathTV.DecMapInt16Uint64V(v, false, d)
  14332. case *map[int16]uint64:
  14333. if v2, changed2 := fastpathTV.DecMapInt16Uint64V(*v, true, d); changed2 {
  14334. *v = v2
  14335. }
  14336. case map[int16]uintptr:
  14337. fastpathTV.DecMapInt16UintptrV(v, false, d)
  14338. case *map[int16]uintptr:
  14339. if v2, changed2 := fastpathTV.DecMapInt16UintptrV(*v, true, d); changed2 {
  14340. *v = v2
  14341. }
  14342. case map[int16]int:
  14343. fastpathTV.DecMapInt16IntV(v, false, d)
  14344. case *map[int16]int:
  14345. if v2, changed2 := fastpathTV.DecMapInt16IntV(*v, true, d); changed2 {
  14346. *v = v2
  14347. }
  14348. case map[int16]int8:
  14349. fastpathTV.DecMapInt16Int8V(v, false, d)
  14350. case *map[int16]int8:
  14351. if v2, changed2 := fastpathTV.DecMapInt16Int8V(*v, true, d); changed2 {
  14352. *v = v2
  14353. }
  14354. case map[int16]int16:
  14355. fastpathTV.DecMapInt16Int16V(v, false, d)
  14356. case *map[int16]int16:
  14357. if v2, changed2 := fastpathTV.DecMapInt16Int16V(*v, true, d); changed2 {
  14358. *v = v2
  14359. }
  14360. case map[int16]int32:
  14361. fastpathTV.DecMapInt16Int32V(v, false, d)
  14362. case *map[int16]int32:
  14363. if v2, changed2 := fastpathTV.DecMapInt16Int32V(*v, true, d); changed2 {
  14364. *v = v2
  14365. }
  14366. case map[int16]int64:
  14367. fastpathTV.DecMapInt16Int64V(v, false, d)
  14368. case *map[int16]int64:
  14369. if v2, changed2 := fastpathTV.DecMapInt16Int64V(*v, true, d); changed2 {
  14370. *v = v2
  14371. }
  14372. case map[int16]float32:
  14373. fastpathTV.DecMapInt16Float32V(v, false, d)
  14374. case *map[int16]float32:
  14375. if v2, changed2 := fastpathTV.DecMapInt16Float32V(*v, true, d); changed2 {
  14376. *v = v2
  14377. }
  14378. case map[int16]float64:
  14379. fastpathTV.DecMapInt16Float64V(v, false, d)
  14380. case *map[int16]float64:
  14381. if v2, changed2 := fastpathTV.DecMapInt16Float64V(*v, true, d); changed2 {
  14382. *v = v2
  14383. }
  14384. case map[int16]bool:
  14385. fastpathTV.DecMapInt16BoolV(v, false, d)
  14386. case *map[int16]bool:
  14387. if v2, changed2 := fastpathTV.DecMapInt16BoolV(*v, true, d); changed2 {
  14388. *v = v2
  14389. }
  14390. case []int32:
  14391. fastpathTV.DecSliceInt32V(v, false, d)
  14392. case *[]int32:
  14393. if v2, changed2 := fastpathTV.DecSliceInt32V(*v, true, d); changed2 {
  14394. *v = v2
  14395. }
  14396. case map[int32]interface{}:
  14397. fastpathTV.DecMapInt32IntfV(v, false, d)
  14398. case *map[int32]interface{}:
  14399. if v2, changed2 := fastpathTV.DecMapInt32IntfV(*v, true, d); changed2 {
  14400. *v = v2
  14401. }
  14402. case map[int32]string:
  14403. fastpathTV.DecMapInt32StringV(v, false, d)
  14404. case *map[int32]string:
  14405. if v2, changed2 := fastpathTV.DecMapInt32StringV(*v, true, d); changed2 {
  14406. *v = v2
  14407. }
  14408. case map[int32]uint:
  14409. fastpathTV.DecMapInt32UintV(v, false, d)
  14410. case *map[int32]uint:
  14411. if v2, changed2 := fastpathTV.DecMapInt32UintV(*v, true, d); changed2 {
  14412. *v = v2
  14413. }
  14414. case map[int32]uint8:
  14415. fastpathTV.DecMapInt32Uint8V(v, false, d)
  14416. case *map[int32]uint8:
  14417. if v2, changed2 := fastpathTV.DecMapInt32Uint8V(*v, true, d); changed2 {
  14418. *v = v2
  14419. }
  14420. case map[int32]uint16:
  14421. fastpathTV.DecMapInt32Uint16V(v, false, d)
  14422. case *map[int32]uint16:
  14423. if v2, changed2 := fastpathTV.DecMapInt32Uint16V(*v, true, d); changed2 {
  14424. *v = v2
  14425. }
  14426. case map[int32]uint32:
  14427. fastpathTV.DecMapInt32Uint32V(v, false, d)
  14428. case *map[int32]uint32:
  14429. if v2, changed2 := fastpathTV.DecMapInt32Uint32V(*v, true, d); changed2 {
  14430. *v = v2
  14431. }
  14432. case map[int32]uint64:
  14433. fastpathTV.DecMapInt32Uint64V(v, false, d)
  14434. case *map[int32]uint64:
  14435. if v2, changed2 := fastpathTV.DecMapInt32Uint64V(*v, true, d); changed2 {
  14436. *v = v2
  14437. }
  14438. case map[int32]uintptr:
  14439. fastpathTV.DecMapInt32UintptrV(v, false, d)
  14440. case *map[int32]uintptr:
  14441. if v2, changed2 := fastpathTV.DecMapInt32UintptrV(*v, true, d); changed2 {
  14442. *v = v2
  14443. }
  14444. case map[int32]int:
  14445. fastpathTV.DecMapInt32IntV(v, false, d)
  14446. case *map[int32]int:
  14447. if v2, changed2 := fastpathTV.DecMapInt32IntV(*v, true, d); changed2 {
  14448. *v = v2
  14449. }
  14450. case map[int32]int8:
  14451. fastpathTV.DecMapInt32Int8V(v, false, d)
  14452. case *map[int32]int8:
  14453. if v2, changed2 := fastpathTV.DecMapInt32Int8V(*v, true, d); changed2 {
  14454. *v = v2
  14455. }
  14456. case map[int32]int16:
  14457. fastpathTV.DecMapInt32Int16V(v, false, d)
  14458. case *map[int32]int16:
  14459. if v2, changed2 := fastpathTV.DecMapInt32Int16V(*v, true, d); changed2 {
  14460. *v = v2
  14461. }
  14462. case map[int32]int32:
  14463. fastpathTV.DecMapInt32Int32V(v, false, d)
  14464. case *map[int32]int32:
  14465. if v2, changed2 := fastpathTV.DecMapInt32Int32V(*v, true, d); changed2 {
  14466. *v = v2
  14467. }
  14468. case map[int32]int64:
  14469. fastpathTV.DecMapInt32Int64V(v, false, d)
  14470. case *map[int32]int64:
  14471. if v2, changed2 := fastpathTV.DecMapInt32Int64V(*v, true, d); changed2 {
  14472. *v = v2
  14473. }
  14474. case map[int32]float32:
  14475. fastpathTV.DecMapInt32Float32V(v, false, d)
  14476. case *map[int32]float32:
  14477. if v2, changed2 := fastpathTV.DecMapInt32Float32V(*v, true, d); changed2 {
  14478. *v = v2
  14479. }
  14480. case map[int32]float64:
  14481. fastpathTV.DecMapInt32Float64V(v, false, d)
  14482. case *map[int32]float64:
  14483. if v2, changed2 := fastpathTV.DecMapInt32Float64V(*v, true, d); changed2 {
  14484. *v = v2
  14485. }
  14486. case map[int32]bool:
  14487. fastpathTV.DecMapInt32BoolV(v, false, d)
  14488. case *map[int32]bool:
  14489. if v2, changed2 := fastpathTV.DecMapInt32BoolV(*v, true, d); changed2 {
  14490. *v = v2
  14491. }
  14492. case []int64:
  14493. fastpathTV.DecSliceInt64V(v, false, d)
  14494. case *[]int64:
  14495. if v2, changed2 := fastpathTV.DecSliceInt64V(*v, true, d); changed2 {
  14496. *v = v2
  14497. }
  14498. case map[int64]interface{}:
  14499. fastpathTV.DecMapInt64IntfV(v, false, d)
  14500. case *map[int64]interface{}:
  14501. if v2, changed2 := fastpathTV.DecMapInt64IntfV(*v, true, d); changed2 {
  14502. *v = v2
  14503. }
  14504. case map[int64]string:
  14505. fastpathTV.DecMapInt64StringV(v, false, d)
  14506. case *map[int64]string:
  14507. if v2, changed2 := fastpathTV.DecMapInt64StringV(*v, true, d); changed2 {
  14508. *v = v2
  14509. }
  14510. case map[int64]uint:
  14511. fastpathTV.DecMapInt64UintV(v, false, d)
  14512. case *map[int64]uint:
  14513. if v2, changed2 := fastpathTV.DecMapInt64UintV(*v, true, d); changed2 {
  14514. *v = v2
  14515. }
  14516. case map[int64]uint8:
  14517. fastpathTV.DecMapInt64Uint8V(v, false, d)
  14518. case *map[int64]uint8:
  14519. if v2, changed2 := fastpathTV.DecMapInt64Uint8V(*v, true, d); changed2 {
  14520. *v = v2
  14521. }
  14522. case map[int64]uint16:
  14523. fastpathTV.DecMapInt64Uint16V(v, false, d)
  14524. case *map[int64]uint16:
  14525. if v2, changed2 := fastpathTV.DecMapInt64Uint16V(*v, true, d); changed2 {
  14526. *v = v2
  14527. }
  14528. case map[int64]uint32:
  14529. fastpathTV.DecMapInt64Uint32V(v, false, d)
  14530. case *map[int64]uint32:
  14531. if v2, changed2 := fastpathTV.DecMapInt64Uint32V(*v, true, d); changed2 {
  14532. *v = v2
  14533. }
  14534. case map[int64]uint64:
  14535. fastpathTV.DecMapInt64Uint64V(v, false, d)
  14536. case *map[int64]uint64:
  14537. if v2, changed2 := fastpathTV.DecMapInt64Uint64V(*v, true, d); changed2 {
  14538. *v = v2
  14539. }
  14540. case map[int64]uintptr:
  14541. fastpathTV.DecMapInt64UintptrV(v, false, d)
  14542. case *map[int64]uintptr:
  14543. if v2, changed2 := fastpathTV.DecMapInt64UintptrV(*v, true, d); changed2 {
  14544. *v = v2
  14545. }
  14546. case map[int64]int:
  14547. fastpathTV.DecMapInt64IntV(v, false, d)
  14548. case *map[int64]int:
  14549. if v2, changed2 := fastpathTV.DecMapInt64IntV(*v, true, d); changed2 {
  14550. *v = v2
  14551. }
  14552. case map[int64]int8:
  14553. fastpathTV.DecMapInt64Int8V(v, false, d)
  14554. case *map[int64]int8:
  14555. if v2, changed2 := fastpathTV.DecMapInt64Int8V(*v, true, d); changed2 {
  14556. *v = v2
  14557. }
  14558. case map[int64]int16:
  14559. fastpathTV.DecMapInt64Int16V(v, false, d)
  14560. case *map[int64]int16:
  14561. if v2, changed2 := fastpathTV.DecMapInt64Int16V(*v, true, d); changed2 {
  14562. *v = v2
  14563. }
  14564. case map[int64]int32:
  14565. fastpathTV.DecMapInt64Int32V(v, false, d)
  14566. case *map[int64]int32:
  14567. if v2, changed2 := fastpathTV.DecMapInt64Int32V(*v, true, d); changed2 {
  14568. *v = v2
  14569. }
  14570. case map[int64]int64:
  14571. fastpathTV.DecMapInt64Int64V(v, false, d)
  14572. case *map[int64]int64:
  14573. if v2, changed2 := fastpathTV.DecMapInt64Int64V(*v, true, d); changed2 {
  14574. *v = v2
  14575. }
  14576. case map[int64]float32:
  14577. fastpathTV.DecMapInt64Float32V(v, false, d)
  14578. case *map[int64]float32:
  14579. if v2, changed2 := fastpathTV.DecMapInt64Float32V(*v, true, d); changed2 {
  14580. *v = v2
  14581. }
  14582. case map[int64]float64:
  14583. fastpathTV.DecMapInt64Float64V(v, false, d)
  14584. case *map[int64]float64:
  14585. if v2, changed2 := fastpathTV.DecMapInt64Float64V(*v, true, d); changed2 {
  14586. *v = v2
  14587. }
  14588. case map[int64]bool:
  14589. fastpathTV.DecMapInt64BoolV(v, false, d)
  14590. case *map[int64]bool:
  14591. if v2, changed2 := fastpathTV.DecMapInt64BoolV(*v, true, d); changed2 {
  14592. *v = v2
  14593. }
  14594. case []bool:
  14595. fastpathTV.DecSliceBoolV(v, false, d)
  14596. case *[]bool:
  14597. if v2, changed2 := fastpathTV.DecSliceBoolV(*v, true, d); changed2 {
  14598. *v = v2
  14599. }
  14600. case map[bool]interface{}:
  14601. fastpathTV.DecMapBoolIntfV(v, false, d)
  14602. case *map[bool]interface{}:
  14603. if v2, changed2 := fastpathTV.DecMapBoolIntfV(*v, true, d); changed2 {
  14604. *v = v2
  14605. }
  14606. case map[bool]string:
  14607. fastpathTV.DecMapBoolStringV(v, false, d)
  14608. case *map[bool]string:
  14609. if v2, changed2 := fastpathTV.DecMapBoolStringV(*v, true, d); changed2 {
  14610. *v = v2
  14611. }
  14612. case map[bool]uint:
  14613. fastpathTV.DecMapBoolUintV(v, false, d)
  14614. case *map[bool]uint:
  14615. if v2, changed2 := fastpathTV.DecMapBoolUintV(*v, true, d); changed2 {
  14616. *v = v2
  14617. }
  14618. case map[bool]uint8:
  14619. fastpathTV.DecMapBoolUint8V(v, false, d)
  14620. case *map[bool]uint8:
  14621. if v2, changed2 := fastpathTV.DecMapBoolUint8V(*v, true, d); changed2 {
  14622. *v = v2
  14623. }
  14624. case map[bool]uint16:
  14625. fastpathTV.DecMapBoolUint16V(v, false, d)
  14626. case *map[bool]uint16:
  14627. if v2, changed2 := fastpathTV.DecMapBoolUint16V(*v, true, d); changed2 {
  14628. *v = v2
  14629. }
  14630. case map[bool]uint32:
  14631. fastpathTV.DecMapBoolUint32V(v, false, d)
  14632. case *map[bool]uint32:
  14633. if v2, changed2 := fastpathTV.DecMapBoolUint32V(*v, true, d); changed2 {
  14634. *v = v2
  14635. }
  14636. case map[bool]uint64:
  14637. fastpathTV.DecMapBoolUint64V(v, false, d)
  14638. case *map[bool]uint64:
  14639. if v2, changed2 := fastpathTV.DecMapBoolUint64V(*v, true, d); changed2 {
  14640. *v = v2
  14641. }
  14642. case map[bool]uintptr:
  14643. fastpathTV.DecMapBoolUintptrV(v, false, d)
  14644. case *map[bool]uintptr:
  14645. if v2, changed2 := fastpathTV.DecMapBoolUintptrV(*v, true, d); changed2 {
  14646. *v = v2
  14647. }
  14648. case map[bool]int:
  14649. fastpathTV.DecMapBoolIntV(v, false, d)
  14650. case *map[bool]int:
  14651. if v2, changed2 := fastpathTV.DecMapBoolIntV(*v, true, d); changed2 {
  14652. *v = v2
  14653. }
  14654. case map[bool]int8:
  14655. fastpathTV.DecMapBoolInt8V(v, false, d)
  14656. case *map[bool]int8:
  14657. if v2, changed2 := fastpathTV.DecMapBoolInt8V(*v, true, d); changed2 {
  14658. *v = v2
  14659. }
  14660. case map[bool]int16:
  14661. fastpathTV.DecMapBoolInt16V(v, false, d)
  14662. case *map[bool]int16:
  14663. if v2, changed2 := fastpathTV.DecMapBoolInt16V(*v, true, d); changed2 {
  14664. *v = v2
  14665. }
  14666. case map[bool]int32:
  14667. fastpathTV.DecMapBoolInt32V(v, false, d)
  14668. case *map[bool]int32:
  14669. if v2, changed2 := fastpathTV.DecMapBoolInt32V(*v, true, d); changed2 {
  14670. *v = v2
  14671. }
  14672. case map[bool]int64:
  14673. fastpathTV.DecMapBoolInt64V(v, false, d)
  14674. case *map[bool]int64:
  14675. if v2, changed2 := fastpathTV.DecMapBoolInt64V(*v, true, d); changed2 {
  14676. *v = v2
  14677. }
  14678. case map[bool]float32:
  14679. fastpathTV.DecMapBoolFloat32V(v, false, d)
  14680. case *map[bool]float32:
  14681. if v2, changed2 := fastpathTV.DecMapBoolFloat32V(*v, true, d); changed2 {
  14682. *v = v2
  14683. }
  14684. case map[bool]float64:
  14685. fastpathTV.DecMapBoolFloat64V(v, false, d)
  14686. case *map[bool]float64:
  14687. if v2, changed2 := fastpathTV.DecMapBoolFloat64V(*v, true, d); changed2 {
  14688. *v = v2
  14689. }
  14690. case map[bool]bool:
  14691. fastpathTV.DecMapBoolBoolV(v, false, d)
  14692. case *map[bool]bool:
  14693. if v2, changed2 := fastpathTV.DecMapBoolBoolV(*v, true, d); changed2 {
  14694. *v = v2
  14695. }
  14696. default:
  14697. _ = v // TODO: workaround https://github.com/golang/go/issues/12927 (remove after go 1.6 release)
  14698. return false
  14699. }
  14700. return true
  14701. }
  14702. func fastpathDecodeSetZeroTypeSwitch(iv interface{}) bool {
  14703. switch v := iv.(type) {
  14704. case *[]interface{}:
  14705. *v = nil
  14706. case *map[interface{}]interface{}:
  14707. *v = nil
  14708. case *map[interface{}]string:
  14709. *v = nil
  14710. case *map[interface{}]uint:
  14711. *v = nil
  14712. case *map[interface{}]uint8:
  14713. *v = nil
  14714. case *map[interface{}]uint16:
  14715. *v = nil
  14716. case *map[interface{}]uint32:
  14717. *v = nil
  14718. case *map[interface{}]uint64:
  14719. *v = nil
  14720. case *map[interface{}]uintptr:
  14721. *v = nil
  14722. case *map[interface{}]int:
  14723. *v = nil
  14724. case *map[interface{}]int8:
  14725. *v = nil
  14726. case *map[interface{}]int16:
  14727. *v = nil
  14728. case *map[interface{}]int32:
  14729. *v = nil
  14730. case *map[interface{}]int64:
  14731. *v = nil
  14732. case *map[interface{}]float32:
  14733. *v = nil
  14734. case *map[interface{}]float64:
  14735. *v = nil
  14736. case *map[interface{}]bool:
  14737. *v = nil
  14738. case *[]string:
  14739. *v = nil
  14740. case *map[string]interface{}:
  14741. *v = nil
  14742. case *map[string]string:
  14743. *v = nil
  14744. case *map[string]uint:
  14745. *v = nil
  14746. case *map[string]uint8:
  14747. *v = nil
  14748. case *map[string]uint16:
  14749. *v = nil
  14750. case *map[string]uint32:
  14751. *v = nil
  14752. case *map[string]uint64:
  14753. *v = nil
  14754. case *map[string]uintptr:
  14755. *v = nil
  14756. case *map[string]int:
  14757. *v = nil
  14758. case *map[string]int8:
  14759. *v = nil
  14760. case *map[string]int16:
  14761. *v = nil
  14762. case *map[string]int32:
  14763. *v = nil
  14764. case *map[string]int64:
  14765. *v = nil
  14766. case *map[string]float32:
  14767. *v = nil
  14768. case *map[string]float64:
  14769. *v = nil
  14770. case *map[string]bool:
  14771. *v = nil
  14772. case *[]float32:
  14773. *v = nil
  14774. case *map[float32]interface{}:
  14775. *v = nil
  14776. case *map[float32]string:
  14777. *v = nil
  14778. case *map[float32]uint:
  14779. *v = nil
  14780. case *map[float32]uint8:
  14781. *v = nil
  14782. case *map[float32]uint16:
  14783. *v = nil
  14784. case *map[float32]uint32:
  14785. *v = nil
  14786. case *map[float32]uint64:
  14787. *v = nil
  14788. case *map[float32]uintptr:
  14789. *v = nil
  14790. case *map[float32]int:
  14791. *v = nil
  14792. case *map[float32]int8:
  14793. *v = nil
  14794. case *map[float32]int16:
  14795. *v = nil
  14796. case *map[float32]int32:
  14797. *v = nil
  14798. case *map[float32]int64:
  14799. *v = nil
  14800. case *map[float32]float32:
  14801. *v = nil
  14802. case *map[float32]float64:
  14803. *v = nil
  14804. case *map[float32]bool:
  14805. *v = nil
  14806. case *[]float64:
  14807. *v = nil
  14808. case *map[float64]interface{}:
  14809. *v = nil
  14810. case *map[float64]string:
  14811. *v = nil
  14812. case *map[float64]uint:
  14813. *v = nil
  14814. case *map[float64]uint8:
  14815. *v = nil
  14816. case *map[float64]uint16:
  14817. *v = nil
  14818. case *map[float64]uint32:
  14819. *v = nil
  14820. case *map[float64]uint64:
  14821. *v = nil
  14822. case *map[float64]uintptr:
  14823. *v = nil
  14824. case *map[float64]int:
  14825. *v = nil
  14826. case *map[float64]int8:
  14827. *v = nil
  14828. case *map[float64]int16:
  14829. *v = nil
  14830. case *map[float64]int32:
  14831. *v = nil
  14832. case *map[float64]int64:
  14833. *v = nil
  14834. case *map[float64]float32:
  14835. *v = nil
  14836. case *map[float64]float64:
  14837. *v = nil
  14838. case *map[float64]bool:
  14839. *v = nil
  14840. case *[]uint:
  14841. *v = nil
  14842. case *map[uint]interface{}:
  14843. *v = nil
  14844. case *map[uint]string:
  14845. *v = nil
  14846. case *map[uint]uint:
  14847. *v = nil
  14848. case *map[uint]uint8:
  14849. *v = nil
  14850. case *map[uint]uint16:
  14851. *v = nil
  14852. case *map[uint]uint32:
  14853. *v = nil
  14854. case *map[uint]uint64:
  14855. *v = nil
  14856. case *map[uint]uintptr:
  14857. *v = nil
  14858. case *map[uint]int:
  14859. *v = nil
  14860. case *map[uint]int8:
  14861. *v = nil
  14862. case *map[uint]int16:
  14863. *v = nil
  14864. case *map[uint]int32:
  14865. *v = nil
  14866. case *map[uint]int64:
  14867. *v = nil
  14868. case *map[uint]float32:
  14869. *v = nil
  14870. case *map[uint]float64:
  14871. *v = nil
  14872. case *map[uint]bool:
  14873. *v = nil
  14874. case *map[uint8]interface{}:
  14875. *v = nil
  14876. case *map[uint8]string:
  14877. *v = nil
  14878. case *map[uint8]uint:
  14879. *v = nil
  14880. case *map[uint8]uint8:
  14881. *v = nil
  14882. case *map[uint8]uint16:
  14883. *v = nil
  14884. case *map[uint8]uint32:
  14885. *v = nil
  14886. case *map[uint8]uint64:
  14887. *v = nil
  14888. case *map[uint8]uintptr:
  14889. *v = nil
  14890. case *map[uint8]int:
  14891. *v = nil
  14892. case *map[uint8]int8:
  14893. *v = nil
  14894. case *map[uint8]int16:
  14895. *v = nil
  14896. case *map[uint8]int32:
  14897. *v = nil
  14898. case *map[uint8]int64:
  14899. *v = nil
  14900. case *map[uint8]float32:
  14901. *v = nil
  14902. case *map[uint8]float64:
  14903. *v = nil
  14904. case *map[uint8]bool:
  14905. *v = nil
  14906. case *[]uint16:
  14907. *v = nil
  14908. case *map[uint16]interface{}:
  14909. *v = nil
  14910. case *map[uint16]string:
  14911. *v = nil
  14912. case *map[uint16]uint:
  14913. *v = nil
  14914. case *map[uint16]uint8:
  14915. *v = nil
  14916. case *map[uint16]uint16:
  14917. *v = nil
  14918. case *map[uint16]uint32:
  14919. *v = nil
  14920. case *map[uint16]uint64:
  14921. *v = nil
  14922. case *map[uint16]uintptr:
  14923. *v = nil
  14924. case *map[uint16]int:
  14925. *v = nil
  14926. case *map[uint16]int8:
  14927. *v = nil
  14928. case *map[uint16]int16:
  14929. *v = nil
  14930. case *map[uint16]int32:
  14931. *v = nil
  14932. case *map[uint16]int64:
  14933. *v = nil
  14934. case *map[uint16]float32:
  14935. *v = nil
  14936. case *map[uint16]float64:
  14937. *v = nil
  14938. case *map[uint16]bool:
  14939. *v = nil
  14940. case *[]uint32:
  14941. *v = nil
  14942. case *map[uint32]interface{}:
  14943. *v = nil
  14944. case *map[uint32]string:
  14945. *v = nil
  14946. case *map[uint32]uint:
  14947. *v = nil
  14948. case *map[uint32]uint8:
  14949. *v = nil
  14950. case *map[uint32]uint16:
  14951. *v = nil
  14952. case *map[uint32]uint32:
  14953. *v = nil
  14954. case *map[uint32]uint64:
  14955. *v = nil
  14956. case *map[uint32]uintptr:
  14957. *v = nil
  14958. case *map[uint32]int:
  14959. *v = nil
  14960. case *map[uint32]int8:
  14961. *v = nil
  14962. case *map[uint32]int16:
  14963. *v = nil
  14964. case *map[uint32]int32:
  14965. *v = nil
  14966. case *map[uint32]int64:
  14967. *v = nil
  14968. case *map[uint32]float32:
  14969. *v = nil
  14970. case *map[uint32]float64:
  14971. *v = nil
  14972. case *map[uint32]bool:
  14973. *v = nil
  14974. case *[]uint64:
  14975. *v = nil
  14976. case *map[uint64]interface{}:
  14977. *v = nil
  14978. case *map[uint64]string:
  14979. *v = nil
  14980. case *map[uint64]uint:
  14981. *v = nil
  14982. case *map[uint64]uint8:
  14983. *v = nil
  14984. case *map[uint64]uint16:
  14985. *v = nil
  14986. case *map[uint64]uint32:
  14987. *v = nil
  14988. case *map[uint64]uint64:
  14989. *v = nil
  14990. case *map[uint64]uintptr:
  14991. *v = nil
  14992. case *map[uint64]int:
  14993. *v = nil
  14994. case *map[uint64]int8:
  14995. *v = nil
  14996. case *map[uint64]int16:
  14997. *v = nil
  14998. case *map[uint64]int32:
  14999. *v = nil
  15000. case *map[uint64]int64:
  15001. *v = nil
  15002. case *map[uint64]float32:
  15003. *v = nil
  15004. case *map[uint64]float64:
  15005. *v = nil
  15006. case *map[uint64]bool:
  15007. *v = nil
  15008. case *[]uintptr:
  15009. *v = nil
  15010. case *map[uintptr]interface{}:
  15011. *v = nil
  15012. case *map[uintptr]string:
  15013. *v = nil
  15014. case *map[uintptr]uint:
  15015. *v = nil
  15016. case *map[uintptr]uint8:
  15017. *v = nil
  15018. case *map[uintptr]uint16:
  15019. *v = nil
  15020. case *map[uintptr]uint32:
  15021. *v = nil
  15022. case *map[uintptr]uint64:
  15023. *v = nil
  15024. case *map[uintptr]uintptr:
  15025. *v = nil
  15026. case *map[uintptr]int:
  15027. *v = nil
  15028. case *map[uintptr]int8:
  15029. *v = nil
  15030. case *map[uintptr]int16:
  15031. *v = nil
  15032. case *map[uintptr]int32:
  15033. *v = nil
  15034. case *map[uintptr]int64:
  15035. *v = nil
  15036. case *map[uintptr]float32:
  15037. *v = nil
  15038. case *map[uintptr]float64:
  15039. *v = nil
  15040. case *map[uintptr]bool:
  15041. *v = nil
  15042. case *[]int:
  15043. *v = nil
  15044. case *map[int]interface{}:
  15045. *v = nil
  15046. case *map[int]string:
  15047. *v = nil
  15048. case *map[int]uint:
  15049. *v = nil
  15050. case *map[int]uint8:
  15051. *v = nil
  15052. case *map[int]uint16:
  15053. *v = nil
  15054. case *map[int]uint32:
  15055. *v = nil
  15056. case *map[int]uint64:
  15057. *v = nil
  15058. case *map[int]uintptr:
  15059. *v = nil
  15060. case *map[int]int:
  15061. *v = nil
  15062. case *map[int]int8:
  15063. *v = nil
  15064. case *map[int]int16:
  15065. *v = nil
  15066. case *map[int]int32:
  15067. *v = nil
  15068. case *map[int]int64:
  15069. *v = nil
  15070. case *map[int]float32:
  15071. *v = nil
  15072. case *map[int]float64:
  15073. *v = nil
  15074. case *map[int]bool:
  15075. *v = nil
  15076. case *[]int8:
  15077. *v = nil
  15078. case *map[int8]interface{}:
  15079. *v = nil
  15080. case *map[int8]string:
  15081. *v = nil
  15082. case *map[int8]uint:
  15083. *v = nil
  15084. case *map[int8]uint8:
  15085. *v = nil
  15086. case *map[int8]uint16:
  15087. *v = nil
  15088. case *map[int8]uint32:
  15089. *v = nil
  15090. case *map[int8]uint64:
  15091. *v = nil
  15092. case *map[int8]uintptr:
  15093. *v = nil
  15094. case *map[int8]int:
  15095. *v = nil
  15096. case *map[int8]int8:
  15097. *v = nil
  15098. case *map[int8]int16:
  15099. *v = nil
  15100. case *map[int8]int32:
  15101. *v = nil
  15102. case *map[int8]int64:
  15103. *v = nil
  15104. case *map[int8]float32:
  15105. *v = nil
  15106. case *map[int8]float64:
  15107. *v = nil
  15108. case *map[int8]bool:
  15109. *v = nil
  15110. case *[]int16:
  15111. *v = nil
  15112. case *map[int16]interface{}:
  15113. *v = nil
  15114. case *map[int16]string:
  15115. *v = nil
  15116. case *map[int16]uint:
  15117. *v = nil
  15118. case *map[int16]uint8:
  15119. *v = nil
  15120. case *map[int16]uint16:
  15121. *v = nil
  15122. case *map[int16]uint32:
  15123. *v = nil
  15124. case *map[int16]uint64:
  15125. *v = nil
  15126. case *map[int16]uintptr:
  15127. *v = nil
  15128. case *map[int16]int:
  15129. *v = nil
  15130. case *map[int16]int8:
  15131. *v = nil
  15132. case *map[int16]int16:
  15133. *v = nil
  15134. case *map[int16]int32:
  15135. *v = nil
  15136. case *map[int16]int64:
  15137. *v = nil
  15138. case *map[int16]float32:
  15139. *v = nil
  15140. case *map[int16]float64:
  15141. *v = nil
  15142. case *map[int16]bool:
  15143. *v = nil
  15144. case *[]int32:
  15145. *v = nil
  15146. case *map[int32]interface{}:
  15147. *v = nil
  15148. case *map[int32]string:
  15149. *v = nil
  15150. case *map[int32]uint:
  15151. *v = nil
  15152. case *map[int32]uint8:
  15153. *v = nil
  15154. case *map[int32]uint16:
  15155. *v = nil
  15156. case *map[int32]uint32:
  15157. *v = nil
  15158. case *map[int32]uint64:
  15159. *v = nil
  15160. case *map[int32]uintptr:
  15161. *v = nil
  15162. case *map[int32]int:
  15163. *v = nil
  15164. case *map[int32]int8:
  15165. *v = nil
  15166. case *map[int32]int16:
  15167. *v = nil
  15168. case *map[int32]int32:
  15169. *v = nil
  15170. case *map[int32]int64:
  15171. *v = nil
  15172. case *map[int32]float32:
  15173. *v = nil
  15174. case *map[int32]float64:
  15175. *v = nil
  15176. case *map[int32]bool:
  15177. *v = nil
  15178. case *[]int64:
  15179. *v = nil
  15180. case *map[int64]interface{}:
  15181. *v = nil
  15182. case *map[int64]string:
  15183. *v = nil
  15184. case *map[int64]uint:
  15185. *v = nil
  15186. case *map[int64]uint8:
  15187. *v = nil
  15188. case *map[int64]uint16:
  15189. *v = nil
  15190. case *map[int64]uint32:
  15191. *v = nil
  15192. case *map[int64]uint64:
  15193. *v = nil
  15194. case *map[int64]uintptr:
  15195. *v = nil
  15196. case *map[int64]int:
  15197. *v = nil
  15198. case *map[int64]int8:
  15199. *v = nil
  15200. case *map[int64]int16:
  15201. *v = nil
  15202. case *map[int64]int32:
  15203. *v = nil
  15204. case *map[int64]int64:
  15205. *v = nil
  15206. case *map[int64]float32:
  15207. *v = nil
  15208. case *map[int64]float64:
  15209. *v = nil
  15210. case *map[int64]bool:
  15211. *v = nil
  15212. case *[]bool:
  15213. *v = nil
  15214. case *map[bool]interface{}:
  15215. *v = nil
  15216. case *map[bool]string:
  15217. *v = nil
  15218. case *map[bool]uint:
  15219. *v = nil
  15220. case *map[bool]uint8:
  15221. *v = nil
  15222. case *map[bool]uint16:
  15223. *v = nil
  15224. case *map[bool]uint32:
  15225. *v = nil
  15226. case *map[bool]uint64:
  15227. *v = nil
  15228. case *map[bool]uintptr:
  15229. *v = nil
  15230. case *map[bool]int:
  15231. *v = nil
  15232. case *map[bool]int8:
  15233. *v = nil
  15234. case *map[bool]int16:
  15235. *v = nil
  15236. case *map[bool]int32:
  15237. *v = nil
  15238. case *map[bool]int64:
  15239. *v = nil
  15240. case *map[bool]float32:
  15241. *v = nil
  15242. case *map[bool]float64:
  15243. *v = nil
  15244. case *map[bool]bool:
  15245. *v = nil
  15246. default:
  15247. _ = v // TODO: workaround https://github.com/golang/go/issues/12927 (remove after go 1.6 release)
  15248. return false
  15249. }
  15250. return true
  15251. }
  15252. // -- -- fast path functions
  15253. func (d *Decoder) fastpathDecSliceIntfR(f *codecFnInfo, rv reflect.Value) {
  15254. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  15255. var vp = rv2i(rv).(*[]interface{})
  15256. if v, changed := fastpathTV.DecSliceIntfV(*vp, !array, d); changed {
  15257. *vp = v
  15258. }
  15259. } else {
  15260. fastpathTV.DecSliceIntfV(rv2i(rv).([]interface{}), !array, d)
  15261. }
  15262. }
  15263. func (f fastpathT) DecSliceIntfX(vp *[]interface{}, d *Decoder) {
  15264. if v, changed := f.DecSliceIntfV(*vp, true, d); changed {
  15265. *vp = v
  15266. }
  15267. }
  15268. func (_ fastpathT) DecSliceIntfV(v []interface{}, canChange bool, d *Decoder) (_ []interface{}, changed bool) {
  15269. dd := d.d
  15270. slh, containerLenS := d.decSliceHelperStart()
  15271. if containerLenS == 0 {
  15272. if canChange {
  15273. if v == nil {
  15274. v = []interface{}{}
  15275. } else if len(v) != 0 {
  15276. v = v[:0]
  15277. }
  15278. changed = true
  15279. }
  15280. slh.End()
  15281. return v, changed
  15282. }
  15283. hasLen := containerLenS > 0
  15284. var xlen int
  15285. if hasLen && canChange {
  15286. if containerLenS > cap(v) {
  15287. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 16)
  15288. if xlen <= cap(v) {
  15289. v = v[:xlen]
  15290. } else {
  15291. v = make([]interface{}, xlen)
  15292. }
  15293. changed = true
  15294. } else if containerLenS != len(v) {
  15295. v = v[:containerLenS]
  15296. changed = true
  15297. }
  15298. }
  15299. j := 0
  15300. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  15301. if j == 0 && len(v) == 0 {
  15302. if hasLen {
  15303. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 16)
  15304. } else {
  15305. xlen = 8
  15306. }
  15307. v = make([]interface{}, xlen)
  15308. changed = true
  15309. }
  15310. // if indefinite, etc, then expand the slice if necessary
  15311. var decodeIntoBlank bool
  15312. if j >= len(v) {
  15313. if canChange {
  15314. v = append(v, nil)
  15315. changed = true
  15316. } else {
  15317. d.arrayCannotExpand(len(v), j+1)
  15318. decodeIntoBlank = true
  15319. }
  15320. }
  15321. slh.ElemContainerState(j)
  15322. if decodeIntoBlank {
  15323. d.swallow()
  15324. } else if dd.TryDecodeAsNil() {
  15325. v[j] = nil
  15326. } else {
  15327. d.decode(&v[j])
  15328. }
  15329. }
  15330. if canChange {
  15331. if j < len(v) {
  15332. v = v[:j]
  15333. changed = true
  15334. } else if j == 0 && v == nil {
  15335. v = make([]interface{}, 0)
  15336. changed = true
  15337. }
  15338. }
  15339. slh.End()
  15340. return v, changed
  15341. }
  15342. func (d *Decoder) fastpathDecSliceStringR(f *codecFnInfo, rv reflect.Value) {
  15343. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  15344. var vp = rv2i(rv).(*[]string)
  15345. if v, changed := fastpathTV.DecSliceStringV(*vp, !array, d); changed {
  15346. *vp = v
  15347. }
  15348. } else {
  15349. fastpathTV.DecSliceStringV(rv2i(rv).([]string), !array, d)
  15350. }
  15351. }
  15352. func (f fastpathT) DecSliceStringX(vp *[]string, d *Decoder) {
  15353. if v, changed := f.DecSliceStringV(*vp, true, d); changed {
  15354. *vp = v
  15355. }
  15356. }
  15357. func (_ fastpathT) DecSliceStringV(v []string, canChange bool, d *Decoder) (_ []string, changed bool) {
  15358. dd := d.d
  15359. slh, containerLenS := d.decSliceHelperStart()
  15360. if containerLenS == 0 {
  15361. if canChange {
  15362. if v == nil {
  15363. v = []string{}
  15364. } else if len(v) != 0 {
  15365. v = v[:0]
  15366. }
  15367. changed = true
  15368. }
  15369. slh.End()
  15370. return v, changed
  15371. }
  15372. hasLen := containerLenS > 0
  15373. var xlen int
  15374. if hasLen && canChange {
  15375. if containerLenS > cap(v) {
  15376. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 16)
  15377. if xlen <= cap(v) {
  15378. v = v[:xlen]
  15379. } else {
  15380. v = make([]string, xlen)
  15381. }
  15382. changed = true
  15383. } else if containerLenS != len(v) {
  15384. v = v[:containerLenS]
  15385. changed = true
  15386. }
  15387. }
  15388. j := 0
  15389. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  15390. if j == 0 && len(v) == 0 {
  15391. if hasLen {
  15392. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 16)
  15393. } else {
  15394. xlen = 8
  15395. }
  15396. v = make([]string, xlen)
  15397. changed = true
  15398. }
  15399. // if indefinite, etc, then expand the slice if necessary
  15400. var decodeIntoBlank bool
  15401. if j >= len(v) {
  15402. if canChange {
  15403. v = append(v, "")
  15404. changed = true
  15405. } else {
  15406. d.arrayCannotExpand(len(v), j+1)
  15407. decodeIntoBlank = true
  15408. }
  15409. }
  15410. slh.ElemContainerState(j)
  15411. if decodeIntoBlank {
  15412. d.swallow()
  15413. } else if dd.TryDecodeAsNil() {
  15414. v[j] = ""
  15415. } else {
  15416. v[j] = dd.DecodeString()
  15417. }
  15418. }
  15419. if canChange {
  15420. if j < len(v) {
  15421. v = v[:j]
  15422. changed = true
  15423. } else if j == 0 && v == nil {
  15424. v = make([]string, 0)
  15425. changed = true
  15426. }
  15427. }
  15428. slh.End()
  15429. return v, changed
  15430. }
  15431. func (d *Decoder) fastpathDecSliceFloat32R(f *codecFnInfo, rv reflect.Value) {
  15432. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  15433. var vp = rv2i(rv).(*[]float32)
  15434. if v, changed := fastpathTV.DecSliceFloat32V(*vp, !array, d); changed {
  15435. *vp = v
  15436. }
  15437. } else {
  15438. fastpathTV.DecSliceFloat32V(rv2i(rv).([]float32), !array, d)
  15439. }
  15440. }
  15441. func (f fastpathT) DecSliceFloat32X(vp *[]float32, d *Decoder) {
  15442. if v, changed := f.DecSliceFloat32V(*vp, true, d); changed {
  15443. *vp = v
  15444. }
  15445. }
  15446. func (_ fastpathT) DecSliceFloat32V(v []float32, canChange bool, d *Decoder) (_ []float32, changed bool) {
  15447. dd := d.d
  15448. slh, containerLenS := d.decSliceHelperStart()
  15449. if containerLenS == 0 {
  15450. if canChange {
  15451. if v == nil {
  15452. v = []float32{}
  15453. } else if len(v) != 0 {
  15454. v = v[:0]
  15455. }
  15456. changed = true
  15457. }
  15458. slh.End()
  15459. return v, changed
  15460. }
  15461. hasLen := containerLenS > 0
  15462. var xlen int
  15463. if hasLen && canChange {
  15464. if containerLenS > cap(v) {
  15465. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 4)
  15466. if xlen <= cap(v) {
  15467. v = v[:xlen]
  15468. } else {
  15469. v = make([]float32, xlen)
  15470. }
  15471. changed = true
  15472. } else if containerLenS != len(v) {
  15473. v = v[:containerLenS]
  15474. changed = true
  15475. }
  15476. }
  15477. j := 0
  15478. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  15479. if j == 0 && len(v) == 0 {
  15480. if hasLen {
  15481. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 4)
  15482. } else {
  15483. xlen = 8
  15484. }
  15485. v = make([]float32, xlen)
  15486. changed = true
  15487. }
  15488. // if indefinite, etc, then expand the slice if necessary
  15489. var decodeIntoBlank bool
  15490. if j >= len(v) {
  15491. if canChange {
  15492. v = append(v, 0)
  15493. changed = true
  15494. } else {
  15495. d.arrayCannotExpand(len(v), j+1)
  15496. decodeIntoBlank = true
  15497. }
  15498. }
  15499. slh.ElemContainerState(j)
  15500. if decodeIntoBlank {
  15501. d.swallow()
  15502. } else if dd.TryDecodeAsNil() {
  15503. v[j] = 0
  15504. } else {
  15505. v[j] = float32(dd.DecodeFloat(true))
  15506. }
  15507. }
  15508. if canChange {
  15509. if j < len(v) {
  15510. v = v[:j]
  15511. changed = true
  15512. } else if j == 0 && v == nil {
  15513. v = make([]float32, 0)
  15514. changed = true
  15515. }
  15516. }
  15517. slh.End()
  15518. return v, changed
  15519. }
  15520. func (d *Decoder) fastpathDecSliceFloat64R(f *codecFnInfo, rv reflect.Value) {
  15521. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  15522. var vp = rv2i(rv).(*[]float64)
  15523. if v, changed := fastpathTV.DecSliceFloat64V(*vp, !array, d); changed {
  15524. *vp = v
  15525. }
  15526. } else {
  15527. fastpathTV.DecSliceFloat64V(rv2i(rv).([]float64), !array, d)
  15528. }
  15529. }
  15530. func (f fastpathT) DecSliceFloat64X(vp *[]float64, d *Decoder) {
  15531. if v, changed := f.DecSliceFloat64V(*vp, true, d); changed {
  15532. *vp = v
  15533. }
  15534. }
  15535. func (_ fastpathT) DecSliceFloat64V(v []float64, canChange bool, d *Decoder) (_ []float64, changed bool) {
  15536. dd := d.d
  15537. slh, containerLenS := d.decSliceHelperStart()
  15538. if containerLenS == 0 {
  15539. if canChange {
  15540. if v == nil {
  15541. v = []float64{}
  15542. } else if len(v) != 0 {
  15543. v = v[:0]
  15544. }
  15545. changed = true
  15546. }
  15547. slh.End()
  15548. return v, changed
  15549. }
  15550. hasLen := containerLenS > 0
  15551. var xlen int
  15552. if hasLen && canChange {
  15553. if containerLenS > cap(v) {
  15554. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 8)
  15555. if xlen <= cap(v) {
  15556. v = v[:xlen]
  15557. } else {
  15558. v = make([]float64, xlen)
  15559. }
  15560. changed = true
  15561. } else if containerLenS != len(v) {
  15562. v = v[:containerLenS]
  15563. changed = true
  15564. }
  15565. }
  15566. j := 0
  15567. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  15568. if j == 0 && len(v) == 0 {
  15569. if hasLen {
  15570. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 8)
  15571. } else {
  15572. xlen = 8
  15573. }
  15574. v = make([]float64, xlen)
  15575. changed = true
  15576. }
  15577. // if indefinite, etc, then expand the slice if necessary
  15578. var decodeIntoBlank bool
  15579. if j >= len(v) {
  15580. if canChange {
  15581. v = append(v, 0)
  15582. changed = true
  15583. } else {
  15584. d.arrayCannotExpand(len(v), j+1)
  15585. decodeIntoBlank = true
  15586. }
  15587. }
  15588. slh.ElemContainerState(j)
  15589. if decodeIntoBlank {
  15590. d.swallow()
  15591. } else if dd.TryDecodeAsNil() {
  15592. v[j] = 0
  15593. } else {
  15594. v[j] = dd.DecodeFloat(false)
  15595. }
  15596. }
  15597. if canChange {
  15598. if j < len(v) {
  15599. v = v[:j]
  15600. changed = true
  15601. } else if j == 0 && v == nil {
  15602. v = make([]float64, 0)
  15603. changed = true
  15604. }
  15605. }
  15606. slh.End()
  15607. return v, changed
  15608. }
  15609. func (d *Decoder) fastpathDecSliceUintR(f *codecFnInfo, rv reflect.Value) {
  15610. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  15611. var vp = rv2i(rv).(*[]uint)
  15612. if v, changed := fastpathTV.DecSliceUintV(*vp, !array, d); changed {
  15613. *vp = v
  15614. }
  15615. } else {
  15616. fastpathTV.DecSliceUintV(rv2i(rv).([]uint), !array, d)
  15617. }
  15618. }
  15619. func (f fastpathT) DecSliceUintX(vp *[]uint, d *Decoder) {
  15620. if v, changed := f.DecSliceUintV(*vp, true, d); changed {
  15621. *vp = v
  15622. }
  15623. }
  15624. func (_ fastpathT) DecSliceUintV(v []uint, canChange bool, d *Decoder) (_ []uint, changed bool) {
  15625. dd := d.d
  15626. slh, containerLenS := d.decSliceHelperStart()
  15627. if containerLenS == 0 {
  15628. if canChange {
  15629. if v == nil {
  15630. v = []uint{}
  15631. } else if len(v) != 0 {
  15632. v = v[:0]
  15633. }
  15634. changed = true
  15635. }
  15636. slh.End()
  15637. return v, changed
  15638. }
  15639. hasLen := containerLenS > 0
  15640. var xlen int
  15641. if hasLen && canChange {
  15642. if containerLenS > cap(v) {
  15643. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 8)
  15644. if xlen <= cap(v) {
  15645. v = v[:xlen]
  15646. } else {
  15647. v = make([]uint, xlen)
  15648. }
  15649. changed = true
  15650. } else if containerLenS != len(v) {
  15651. v = v[:containerLenS]
  15652. changed = true
  15653. }
  15654. }
  15655. j := 0
  15656. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  15657. if j == 0 && len(v) == 0 {
  15658. if hasLen {
  15659. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 8)
  15660. } else {
  15661. xlen = 8
  15662. }
  15663. v = make([]uint, xlen)
  15664. changed = true
  15665. }
  15666. // if indefinite, etc, then expand the slice if necessary
  15667. var decodeIntoBlank bool
  15668. if j >= len(v) {
  15669. if canChange {
  15670. v = append(v, 0)
  15671. changed = true
  15672. } else {
  15673. d.arrayCannotExpand(len(v), j+1)
  15674. decodeIntoBlank = true
  15675. }
  15676. }
  15677. slh.ElemContainerState(j)
  15678. if decodeIntoBlank {
  15679. d.swallow()
  15680. } else if dd.TryDecodeAsNil() {
  15681. v[j] = 0
  15682. } else {
  15683. v[j] = uint(dd.DecodeUint(uintBitsize))
  15684. }
  15685. }
  15686. if canChange {
  15687. if j < len(v) {
  15688. v = v[:j]
  15689. changed = true
  15690. } else if j == 0 && v == nil {
  15691. v = make([]uint, 0)
  15692. changed = true
  15693. }
  15694. }
  15695. slh.End()
  15696. return v, changed
  15697. }
  15698. func (d *Decoder) fastpathDecSliceUint16R(f *codecFnInfo, rv reflect.Value) {
  15699. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  15700. var vp = rv2i(rv).(*[]uint16)
  15701. if v, changed := fastpathTV.DecSliceUint16V(*vp, !array, d); changed {
  15702. *vp = v
  15703. }
  15704. } else {
  15705. fastpathTV.DecSliceUint16V(rv2i(rv).([]uint16), !array, d)
  15706. }
  15707. }
  15708. func (f fastpathT) DecSliceUint16X(vp *[]uint16, d *Decoder) {
  15709. if v, changed := f.DecSliceUint16V(*vp, true, d); changed {
  15710. *vp = v
  15711. }
  15712. }
  15713. func (_ fastpathT) DecSliceUint16V(v []uint16, canChange bool, d *Decoder) (_ []uint16, changed bool) {
  15714. dd := d.d
  15715. slh, containerLenS := d.decSliceHelperStart()
  15716. if containerLenS == 0 {
  15717. if canChange {
  15718. if v == nil {
  15719. v = []uint16{}
  15720. } else if len(v) != 0 {
  15721. v = v[:0]
  15722. }
  15723. changed = true
  15724. }
  15725. slh.End()
  15726. return v, changed
  15727. }
  15728. hasLen := containerLenS > 0
  15729. var xlen int
  15730. if hasLen && canChange {
  15731. if containerLenS > cap(v) {
  15732. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 2)
  15733. if xlen <= cap(v) {
  15734. v = v[:xlen]
  15735. } else {
  15736. v = make([]uint16, xlen)
  15737. }
  15738. changed = true
  15739. } else if containerLenS != len(v) {
  15740. v = v[:containerLenS]
  15741. changed = true
  15742. }
  15743. }
  15744. j := 0
  15745. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  15746. if j == 0 && len(v) == 0 {
  15747. if hasLen {
  15748. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 2)
  15749. } else {
  15750. xlen = 8
  15751. }
  15752. v = make([]uint16, xlen)
  15753. changed = true
  15754. }
  15755. // if indefinite, etc, then expand the slice if necessary
  15756. var decodeIntoBlank bool
  15757. if j >= len(v) {
  15758. if canChange {
  15759. v = append(v, 0)
  15760. changed = true
  15761. } else {
  15762. d.arrayCannotExpand(len(v), j+1)
  15763. decodeIntoBlank = true
  15764. }
  15765. }
  15766. slh.ElemContainerState(j)
  15767. if decodeIntoBlank {
  15768. d.swallow()
  15769. } else if dd.TryDecodeAsNil() {
  15770. v[j] = 0
  15771. } else {
  15772. v[j] = uint16(dd.DecodeUint(16))
  15773. }
  15774. }
  15775. if canChange {
  15776. if j < len(v) {
  15777. v = v[:j]
  15778. changed = true
  15779. } else if j == 0 && v == nil {
  15780. v = make([]uint16, 0)
  15781. changed = true
  15782. }
  15783. }
  15784. slh.End()
  15785. return v, changed
  15786. }
  15787. func (d *Decoder) fastpathDecSliceUint32R(f *codecFnInfo, rv reflect.Value) {
  15788. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  15789. var vp = rv2i(rv).(*[]uint32)
  15790. if v, changed := fastpathTV.DecSliceUint32V(*vp, !array, d); changed {
  15791. *vp = v
  15792. }
  15793. } else {
  15794. fastpathTV.DecSliceUint32V(rv2i(rv).([]uint32), !array, d)
  15795. }
  15796. }
  15797. func (f fastpathT) DecSliceUint32X(vp *[]uint32, d *Decoder) {
  15798. if v, changed := f.DecSliceUint32V(*vp, true, d); changed {
  15799. *vp = v
  15800. }
  15801. }
  15802. func (_ fastpathT) DecSliceUint32V(v []uint32, canChange bool, d *Decoder) (_ []uint32, changed bool) {
  15803. dd := d.d
  15804. slh, containerLenS := d.decSliceHelperStart()
  15805. if containerLenS == 0 {
  15806. if canChange {
  15807. if v == nil {
  15808. v = []uint32{}
  15809. } else if len(v) != 0 {
  15810. v = v[:0]
  15811. }
  15812. changed = true
  15813. }
  15814. slh.End()
  15815. return v, changed
  15816. }
  15817. hasLen := containerLenS > 0
  15818. var xlen int
  15819. if hasLen && canChange {
  15820. if containerLenS > cap(v) {
  15821. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 4)
  15822. if xlen <= cap(v) {
  15823. v = v[:xlen]
  15824. } else {
  15825. v = make([]uint32, xlen)
  15826. }
  15827. changed = true
  15828. } else if containerLenS != len(v) {
  15829. v = v[:containerLenS]
  15830. changed = true
  15831. }
  15832. }
  15833. j := 0
  15834. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  15835. if j == 0 && len(v) == 0 {
  15836. if hasLen {
  15837. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 4)
  15838. } else {
  15839. xlen = 8
  15840. }
  15841. v = make([]uint32, xlen)
  15842. changed = true
  15843. }
  15844. // if indefinite, etc, then expand the slice if necessary
  15845. var decodeIntoBlank bool
  15846. if j >= len(v) {
  15847. if canChange {
  15848. v = append(v, 0)
  15849. changed = true
  15850. } else {
  15851. d.arrayCannotExpand(len(v), j+1)
  15852. decodeIntoBlank = true
  15853. }
  15854. }
  15855. slh.ElemContainerState(j)
  15856. if decodeIntoBlank {
  15857. d.swallow()
  15858. } else if dd.TryDecodeAsNil() {
  15859. v[j] = 0
  15860. } else {
  15861. v[j] = uint32(dd.DecodeUint(32))
  15862. }
  15863. }
  15864. if canChange {
  15865. if j < len(v) {
  15866. v = v[:j]
  15867. changed = true
  15868. } else if j == 0 && v == nil {
  15869. v = make([]uint32, 0)
  15870. changed = true
  15871. }
  15872. }
  15873. slh.End()
  15874. return v, changed
  15875. }
  15876. func (d *Decoder) fastpathDecSliceUint64R(f *codecFnInfo, rv reflect.Value) {
  15877. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  15878. var vp = rv2i(rv).(*[]uint64)
  15879. if v, changed := fastpathTV.DecSliceUint64V(*vp, !array, d); changed {
  15880. *vp = v
  15881. }
  15882. } else {
  15883. fastpathTV.DecSliceUint64V(rv2i(rv).([]uint64), !array, d)
  15884. }
  15885. }
  15886. func (f fastpathT) DecSliceUint64X(vp *[]uint64, d *Decoder) {
  15887. if v, changed := f.DecSliceUint64V(*vp, true, d); changed {
  15888. *vp = v
  15889. }
  15890. }
  15891. func (_ fastpathT) DecSliceUint64V(v []uint64, canChange bool, d *Decoder) (_ []uint64, changed bool) {
  15892. dd := d.d
  15893. slh, containerLenS := d.decSliceHelperStart()
  15894. if containerLenS == 0 {
  15895. if canChange {
  15896. if v == nil {
  15897. v = []uint64{}
  15898. } else if len(v) != 0 {
  15899. v = v[:0]
  15900. }
  15901. changed = true
  15902. }
  15903. slh.End()
  15904. return v, changed
  15905. }
  15906. hasLen := containerLenS > 0
  15907. var xlen int
  15908. if hasLen && canChange {
  15909. if containerLenS > cap(v) {
  15910. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 8)
  15911. if xlen <= cap(v) {
  15912. v = v[:xlen]
  15913. } else {
  15914. v = make([]uint64, xlen)
  15915. }
  15916. changed = true
  15917. } else if containerLenS != len(v) {
  15918. v = v[:containerLenS]
  15919. changed = true
  15920. }
  15921. }
  15922. j := 0
  15923. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  15924. if j == 0 && len(v) == 0 {
  15925. if hasLen {
  15926. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 8)
  15927. } else {
  15928. xlen = 8
  15929. }
  15930. v = make([]uint64, xlen)
  15931. changed = true
  15932. }
  15933. // if indefinite, etc, then expand the slice if necessary
  15934. var decodeIntoBlank bool
  15935. if j >= len(v) {
  15936. if canChange {
  15937. v = append(v, 0)
  15938. changed = true
  15939. } else {
  15940. d.arrayCannotExpand(len(v), j+1)
  15941. decodeIntoBlank = true
  15942. }
  15943. }
  15944. slh.ElemContainerState(j)
  15945. if decodeIntoBlank {
  15946. d.swallow()
  15947. } else if dd.TryDecodeAsNil() {
  15948. v[j] = 0
  15949. } else {
  15950. v[j] = dd.DecodeUint(64)
  15951. }
  15952. }
  15953. if canChange {
  15954. if j < len(v) {
  15955. v = v[:j]
  15956. changed = true
  15957. } else if j == 0 && v == nil {
  15958. v = make([]uint64, 0)
  15959. changed = true
  15960. }
  15961. }
  15962. slh.End()
  15963. return v, changed
  15964. }
  15965. func (d *Decoder) fastpathDecSliceUintptrR(f *codecFnInfo, rv reflect.Value) {
  15966. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  15967. var vp = rv2i(rv).(*[]uintptr)
  15968. if v, changed := fastpathTV.DecSliceUintptrV(*vp, !array, d); changed {
  15969. *vp = v
  15970. }
  15971. } else {
  15972. fastpathTV.DecSliceUintptrV(rv2i(rv).([]uintptr), !array, d)
  15973. }
  15974. }
  15975. func (f fastpathT) DecSliceUintptrX(vp *[]uintptr, d *Decoder) {
  15976. if v, changed := f.DecSliceUintptrV(*vp, true, d); changed {
  15977. *vp = v
  15978. }
  15979. }
  15980. func (_ fastpathT) DecSliceUintptrV(v []uintptr, canChange bool, d *Decoder) (_ []uintptr, changed bool) {
  15981. dd := d.d
  15982. slh, containerLenS := d.decSliceHelperStart()
  15983. if containerLenS == 0 {
  15984. if canChange {
  15985. if v == nil {
  15986. v = []uintptr{}
  15987. } else if len(v) != 0 {
  15988. v = v[:0]
  15989. }
  15990. changed = true
  15991. }
  15992. slh.End()
  15993. return v, changed
  15994. }
  15995. hasLen := containerLenS > 0
  15996. var xlen int
  15997. if hasLen && canChange {
  15998. if containerLenS > cap(v) {
  15999. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 8)
  16000. if xlen <= cap(v) {
  16001. v = v[:xlen]
  16002. } else {
  16003. v = make([]uintptr, xlen)
  16004. }
  16005. changed = true
  16006. } else if containerLenS != len(v) {
  16007. v = v[:containerLenS]
  16008. changed = true
  16009. }
  16010. }
  16011. j := 0
  16012. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  16013. if j == 0 && len(v) == 0 {
  16014. if hasLen {
  16015. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 8)
  16016. } else {
  16017. xlen = 8
  16018. }
  16019. v = make([]uintptr, xlen)
  16020. changed = true
  16021. }
  16022. // if indefinite, etc, then expand the slice if necessary
  16023. var decodeIntoBlank bool
  16024. if j >= len(v) {
  16025. if canChange {
  16026. v = append(v, 0)
  16027. changed = true
  16028. } else {
  16029. d.arrayCannotExpand(len(v), j+1)
  16030. decodeIntoBlank = true
  16031. }
  16032. }
  16033. slh.ElemContainerState(j)
  16034. if decodeIntoBlank {
  16035. d.swallow()
  16036. } else if dd.TryDecodeAsNil() {
  16037. v[j] = 0
  16038. } else {
  16039. v[j] = uintptr(dd.DecodeUint(uintBitsize))
  16040. }
  16041. }
  16042. if canChange {
  16043. if j < len(v) {
  16044. v = v[:j]
  16045. changed = true
  16046. } else if j == 0 && v == nil {
  16047. v = make([]uintptr, 0)
  16048. changed = true
  16049. }
  16050. }
  16051. slh.End()
  16052. return v, changed
  16053. }
  16054. func (d *Decoder) fastpathDecSliceIntR(f *codecFnInfo, rv reflect.Value) {
  16055. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  16056. var vp = rv2i(rv).(*[]int)
  16057. if v, changed := fastpathTV.DecSliceIntV(*vp, !array, d); changed {
  16058. *vp = v
  16059. }
  16060. } else {
  16061. fastpathTV.DecSliceIntV(rv2i(rv).([]int), !array, d)
  16062. }
  16063. }
  16064. func (f fastpathT) DecSliceIntX(vp *[]int, d *Decoder) {
  16065. if v, changed := f.DecSliceIntV(*vp, true, d); changed {
  16066. *vp = v
  16067. }
  16068. }
  16069. func (_ fastpathT) DecSliceIntV(v []int, canChange bool, d *Decoder) (_ []int, changed bool) {
  16070. dd := d.d
  16071. slh, containerLenS := d.decSliceHelperStart()
  16072. if containerLenS == 0 {
  16073. if canChange {
  16074. if v == nil {
  16075. v = []int{}
  16076. } else if len(v) != 0 {
  16077. v = v[:0]
  16078. }
  16079. changed = true
  16080. }
  16081. slh.End()
  16082. return v, changed
  16083. }
  16084. hasLen := containerLenS > 0
  16085. var xlen int
  16086. if hasLen && canChange {
  16087. if containerLenS > cap(v) {
  16088. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 8)
  16089. if xlen <= cap(v) {
  16090. v = v[:xlen]
  16091. } else {
  16092. v = make([]int, xlen)
  16093. }
  16094. changed = true
  16095. } else if containerLenS != len(v) {
  16096. v = v[:containerLenS]
  16097. changed = true
  16098. }
  16099. }
  16100. j := 0
  16101. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  16102. if j == 0 && len(v) == 0 {
  16103. if hasLen {
  16104. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 8)
  16105. } else {
  16106. xlen = 8
  16107. }
  16108. v = make([]int, xlen)
  16109. changed = true
  16110. }
  16111. // if indefinite, etc, then expand the slice if necessary
  16112. var decodeIntoBlank bool
  16113. if j >= len(v) {
  16114. if canChange {
  16115. v = append(v, 0)
  16116. changed = true
  16117. } else {
  16118. d.arrayCannotExpand(len(v), j+1)
  16119. decodeIntoBlank = true
  16120. }
  16121. }
  16122. slh.ElemContainerState(j)
  16123. if decodeIntoBlank {
  16124. d.swallow()
  16125. } else if dd.TryDecodeAsNil() {
  16126. v[j] = 0
  16127. } else {
  16128. v[j] = int(dd.DecodeInt(intBitsize))
  16129. }
  16130. }
  16131. if canChange {
  16132. if j < len(v) {
  16133. v = v[:j]
  16134. changed = true
  16135. } else if j == 0 && v == nil {
  16136. v = make([]int, 0)
  16137. changed = true
  16138. }
  16139. }
  16140. slh.End()
  16141. return v, changed
  16142. }
  16143. func (d *Decoder) fastpathDecSliceInt8R(f *codecFnInfo, rv reflect.Value) {
  16144. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  16145. var vp = rv2i(rv).(*[]int8)
  16146. if v, changed := fastpathTV.DecSliceInt8V(*vp, !array, d); changed {
  16147. *vp = v
  16148. }
  16149. } else {
  16150. fastpathTV.DecSliceInt8V(rv2i(rv).([]int8), !array, d)
  16151. }
  16152. }
  16153. func (f fastpathT) DecSliceInt8X(vp *[]int8, d *Decoder) {
  16154. if v, changed := f.DecSliceInt8V(*vp, true, d); changed {
  16155. *vp = v
  16156. }
  16157. }
  16158. func (_ fastpathT) DecSliceInt8V(v []int8, canChange bool, d *Decoder) (_ []int8, changed bool) {
  16159. dd := d.d
  16160. slh, containerLenS := d.decSliceHelperStart()
  16161. if containerLenS == 0 {
  16162. if canChange {
  16163. if v == nil {
  16164. v = []int8{}
  16165. } else if len(v) != 0 {
  16166. v = v[:0]
  16167. }
  16168. changed = true
  16169. }
  16170. slh.End()
  16171. return v, changed
  16172. }
  16173. hasLen := containerLenS > 0
  16174. var xlen int
  16175. if hasLen && canChange {
  16176. if containerLenS > cap(v) {
  16177. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 1)
  16178. if xlen <= cap(v) {
  16179. v = v[:xlen]
  16180. } else {
  16181. v = make([]int8, xlen)
  16182. }
  16183. changed = true
  16184. } else if containerLenS != len(v) {
  16185. v = v[:containerLenS]
  16186. changed = true
  16187. }
  16188. }
  16189. j := 0
  16190. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  16191. if j == 0 && len(v) == 0 {
  16192. if hasLen {
  16193. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 1)
  16194. } else {
  16195. xlen = 8
  16196. }
  16197. v = make([]int8, xlen)
  16198. changed = true
  16199. }
  16200. // if indefinite, etc, then expand the slice if necessary
  16201. var decodeIntoBlank bool
  16202. if j >= len(v) {
  16203. if canChange {
  16204. v = append(v, 0)
  16205. changed = true
  16206. } else {
  16207. d.arrayCannotExpand(len(v), j+1)
  16208. decodeIntoBlank = true
  16209. }
  16210. }
  16211. slh.ElemContainerState(j)
  16212. if decodeIntoBlank {
  16213. d.swallow()
  16214. } else if dd.TryDecodeAsNil() {
  16215. v[j] = 0
  16216. } else {
  16217. v[j] = int8(dd.DecodeInt(8))
  16218. }
  16219. }
  16220. if canChange {
  16221. if j < len(v) {
  16222. v = v[:j]
  16223. changed = true
  16224. } else if j == 0 && v == nil {
  16225. v = make([]int8, 0)
  16226. changed = true
  16227. }
  16228. }
  16229. slh.End()
  16230. return v, changed
  16231. }
  16232. func (d *Decoder) fastpathDecSliceInt16R(f *codecFnInfo, rv reflect.Value) {
  16233. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  16234. var vp = rv2i(rv).(*[]int16)
  16235. if v, changed := fastpathTV.DecSliceInt16V(*vp, !array, d); changed {
  16236. *vp = v
  16237. }
  16238. } else {
  16239. fastpathTV.DecSliceInt16V(rv2i(rv).([]int16), !array, d)
  16240. }
  16241. }
  16242. func (f fastpathT) DecSliceInt16X(vp *[]int16, d *Decoder) {
  16243. if v, changed := f.DecSliceInt16V(*vp, true, d); changed {
  16244. *vp = v
  16245. }
  16246. }
  16247. func (_ fastpathT) DecSliceInt16V(v []int16, canChange bool, d *Decoder) (_ []int16, changed bool) {
  16248. dd := d.d
  16249. slh, containerLenS := d.decSliceHelperStart()
  16250. if containerLenS == 0 {
  16251. if canChange {
  16252. if v == nil {
  16253. v = []int16{}
  16254. } else if len(v) != 0 {
  16255. v = v[:0]
  16256. }
  16257. changed = true
  16258. }
  16259. slh.End()
  16260. return v, changed
  16261. }
  16262. hasLen := containerLenS > 0
  16263. var xlen int
  16264. if hasLen && canChange {
  16265. if containerLenS > cap(v) {
  16266. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 2)
  16267. if xlen <= cap(v) {
  16268. v = v[:xlen]
  16269. } else {
  16270. v = make([]int16, xlen)
  16271. }
  16272. changed = true
  16273. } else if containerLenS != len(v) {
  16274. v = v[:containerLenS]
  16275. changed = true
  16276. }
  16277. }
  16278. j := 0
  16279. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  16280. if j == 0 && len(v) == 0 {
  16281. if hasLen {
  16282. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 2)
  16283. } else {
  16284. xlen = 8
  16285. }
  16286. v = make([]int16, xlen)
  16287. changed = true
  16288. }
  16289. // if indefinite, etc, then expand the slice if necessary
  16290. var decodeIntoBlank bool
  16291. if j >= len(v) {
  16292. if canChange {
  16293. v = append(v, 0)
  16294. changed = true
  16295. } else {
  16296. d.arrayCannotExpand(len(v), j+1)
  16297. decodeIntoBlank = true
  16298. }
  16299. }
  16300. slh.ElemContainerState(j)
  16301. if decodeIntoBlank {
  16302. d.swallow()
  16303. } else if dd.TryDecodeAsNil() {
  16304. v[j] = 0
  16305. } else {
  16306. v[j] = int16(dd.DecodeInt(16))
  16307. }
  16308. }
  16309. if canChange {
  16310. if j < len(v) {
  16311. v = v[:j]
  16312. changed = true
  16313. } else if j == 0 && v == nil {
  16314. v = make([]int16, 0)
  16315. changed = true
  16316. }
  16317. }
  16318. slh.End()
  16319. return v, changed
  16320. }
  16321. func (d *Decoder) fastpathDecSliceInt32R(f *codecFnInfo, rv reflect.Value) {
  16322. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  16323. var vp = rv2i(rv).(*[]int32)
  16324. if v, changed := fastpathTV.DecSliceInt32V(*vp, !array, d); changed {
  16325. *vp = v
  16326. }
  16327. } else {
  16328. fastpathTV.DecSliceInt32V(rv2i(rv).([]int32), !array, d)
  16329. }
  16330. }
  16331. func (f fastpathT) DecSliceInt32X(vp *[]int32, d *Decoder) {
  16332. if v, changed := f.DecSliceInt32V(*vp, true, d); changed {
  16333. *vp = v
  16334. }
  16335. }
  16336. func (_ fastpathT) DecSliceInt32V(v []int32, canChange bool, d *Decoder) (_ []int32, changed bool) {
  16337. dd := d.d
  16338. slh, containerLenS := d.decSliceHelperStart()
  16339. if containerLenS == 0 {
  16340. if canChange {
  16341. if v == nil {
  16342. v = []int32{}
  16343. } else if len(v) != 0 {
  16344. v = v[:0]
  16345. }
  16346. changed = true
  16347. }
  16348. slh.End()
  16349. return v, changed
  16350. }
  16351. hasLen := containerLenS > 0
  16352. var xlen int
  16353. if hasLen && canChange {
  16354. if containerLenS > cap(v) {
  16355. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 4)
  16356. if xlen <= cap(v) {
  16357. v = v[:xlen]
  16358. } else {
  16359. v = make([]int32, xlen)
  16360. }
  16361. changed = true
  16362. } else if containerLenS != len(v) {
  16363. v = v[:containerLenS]
  16364. changed = true
  16365. }
  16366. }
  16367. j := 0
  16368. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  16369. if j == 0 && len(v) == 0 {
  16370. if hasLen {
  16371. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 4)
  16372. } else {
  16373. xlen = 8
  16374. }
  16375. v = make([]int32, xlen)
  16376. changed = true
  16377. }
  16378. // if indefinite, etc, then expand the slice if necessary
  16379. var decodeIntoBlank bool
  16380. if j >= len(v) {
  16381. if canChange {
  16382. v = append(v, 0)
  16383. changed = true
  16384. } else {
  16385. d.arrayCannotExpand(len(v), j+1)
  16386. decodeIntoBlank = true
  16387. }
  16388. }
  16389. slh.ElemContainerState(j)
  16390. if decodeIntoBlank {
  16391. d.swallow()
  16392. } else if dd.TryDecodeAsNil() {
  16393. v[j] = 0
  16394. } else {
  16395. v[j] = int32(dd.DecodeInt(32))
  16396. }
  16397. }
  16398. if canChange {
  16399. if j < len(v) {
  16400. v = v[:j]
  16401. changed = true
  16402. } else if j == 0 && v == nil {
  16403. v = make([]int32, 0)
  16404. changed = true
  16405. }
  16406. }
  16407. slh.End()
  16408. return v, changed
  16409. }
  16410. func (d *Decoder) fastpathDecSliceInt64R(f *codecFnInfo, rv reflect.Value) {
  16411. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  16412. var vp = rv2i(rv).(*[]int64)
  16413. if v, changed := fastpathTV.DecSliceInt64V(*vp, !array, d); changed {
  16414. *vp = v
  16415. }
  16416. } else {
  16417. fastpathTV.DecSliceInt64V(rv2i(rv).([]int64), !array, d)
  16418. }
  16419. }
  16420. func (f fastpathT) DecSliceInt64X(vp *[]int64, d *Decoder) {
  16421. if v, changed := f.DecSliceInt64V(*vp, true, d); changed {
  16422. *vp = v
  16423. }
  16424. }
  16425. func (_ fastpathT) DecSliceInt64V(v []int64, canChange bool, d *Decoder) (_ []int64, changed bool) {
  16426. dd := d.d
  16427. slh, containerLenS := d.decSliceHelperStart()
  16428. if containerLenS == 0 {
  16429. if canChange {
  16430. if v == nil {
  16431. v = []int64{}
  16432. } else if len(v) != 0 {
  16433. v = v[:0]
  16434. }
  16435. changed = true
  16436. }
  16437. slh.End()
  16438. return v, changed
  16439. }
  16440. hasLen := containerLenS > 0
  16441. var xlen int
  16442. if hasLen && canChange {
  16443. if containerLenS > cap(v) {
  16444. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 8)
  16445. if xlen <= cap(v) {
  16446. v = v[:xlen]
  16447. } else {
  16448. v = make([]int64, xlen)
  16449. }
  16450. changed = true
  16451. } else if containerLenS != len(v) {
  16452. v = v[:containerLenS]
  16453. changed = true
  16454. }
  16455. }
  16456. j := 0
  16457. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  16458. if j == 0 && len(v) == 0 {
  16459. if hasLen {
  16460. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 8)
  16461. } else {
  16462. xlen = 8
  16463. }
  16464. v = make([]int64, xlen)
  16465. changed = true
  16466. }
  16467. // if indefinite, etc, then expand the slice if necessary
  16468. var decodeIntoBlank bool
  16469. if j >= len(v) {
  16470. if canChange {
  16471. v = append(v, 0)
  16472. changed = true
  16473. } else {
  16474. d.arrayCannotExpand(len(v), j+1)
  16475. decodeIntoBlank = true
  16476. }
  16477. }
  16478. slh.ElemContainerState(j)
  16479. if decodeIntoBlank {
  16480. d.swallow()
  16481. } else if dd.TryDecodeAsNil() {
  16482. v[j] = 0
  16483. } else {
  16484. v[j] = dd.DecodeInt(64)
  16485. }
  16486. }
  16487. if canChange {
  16488. if j < len(v) {
  16489. v = v[:j]
  16490. changed = true
  16491. } else if j == 0 && v == nil {
  16492. v = make([]int64, 0)
  16493. changed = true
  16494. }
  16495. }
  16496. slh.End()
  16497. return v, changed
  16498. }
  16499. func (d *Decoder) fastpathDecSliceBoolR(f *codecFnInfo, rv reflect.Value) {
  16500. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  16501. var vp = rv2i(rv).(*[]bool)
  16502. if v, changed := fastpathTV.DecSliceBoolV(*vp, !array, d); changed {
  16503. *vp = v
  16504. }
  16505. } else {
  16506. fastpathTV.DecSliceBoolV(rv2i(rv).([]bool), !array, d)
  16507. }
  16508. }
  16509. func (f fastpathT) DecSliceBoolX(vp *[]bool, d *Decoder) {
  16510. if v, changed := f.DecSliceBoolV(*vp, true, d); changed {
  16511. *vp = v
  16512. }
  16513. }
  16514. func (_ fastpathT) DecSliceBoolV(v []bool, canChange bool, d *Decoder) (_ []bool, changed bool) {
  16515. dd := d.d
  16516. slh, containerLenS := d.decSliceHelperStart()
  16517. if containerLenS == 0 {
  16518. if canChange {
  16519. if v == nil {
  16520. v = []bool{}
  16521. } else if len(v) != 0 {
  16522. v = v[:0]
  16523. }
  16524. changed = true
  16525. }
  16526. slh.End()
  16527. return v, changed
  16528. }
  16529. hasLen := containerLenS > 0
  16530. var xlen int
  16531. if hasLen && canChange {
  16532. if containerLenS > cap(v) {
  16533. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 1)
  16534. if xlen <= cap(v) {
  16535. v = v[:xlen]
  16536. } else {
  16537. v = make([]bool, xlen)
  16538. }
  16539. changed = true
  16540. } else if containerLenS != len(v) {
  16541. v = v[:containerLenS]
  16542. changed = true
  16543. }
  16544. }
  16545. j := 0
  16546. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  16547. if j == 0 && len(v) == 0 {
  16548. if hasLen {
  16549. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 1)
  16550. } else {
  16551. xlen = 8
  16552. }
  16553. v = make([]bool, xlen)
  16554. changed = true
  16555. }
  16556. // if indefinite, etc, then expand the slice if necessary
  16557. var decodeIntoBlank bool
  16558. if j >= len(v) {
  16559. if canChange {
  16560. v = append(v, false)
  16561. changed = true
  16562. } else {
  16563. d.arrayCannotExpand(len(v), j+1)
  16564. decodeIntoBlank = true
  16565. }
  16566. }
  16567. slh.ElemContainerState(j)
  16568. if decodeIntoBlank {
  16569. d.swallow()
  16570. } else if dd.TryDecodeAsNil() {
  16571. v[j] = false
  16572. } else {
  16573. v[j] = dd.DecodeBool()
  16574. }
  16575. }
  16576. if canChange {
  16577. if j < len(v) {
  16578. v = v[:j]
  16579. changed = true
  16580. } else if j == 0 && v == nil {
  16581. v = make([]bool, 0)
  16582. changed = true
  16583. }
  16584. }
  16585. slh.End()
  16586. return v, changed
  16587. }
  16588. func (d *Decoder) fastpathDecMapIntfIntfR(f *codecFnInfo, rv reflect.Value) {
  16589. if rv.Kind() == reflect.Ptr {
  16590. vp := rv2i(rv).(*map[interface{}]interface{})
  16591. if v, changed := fastpathTV.DecMapIntfIntfV(*vp, true, d); changed {
  16592. *vp = v
  16593. }
  16594. return
  16595. }
  16596. fastpathTV.DecMapIntfIntfV(rv2i(rv).(map[interface{}]interface{}), false, d)
  16597. }
  16598. func (f fastpathT) DecMapIntfIntfX(vp *map[interface{}]interface{}, d *Decoder) {
  16599. if v, changed := f.DecMapIntfIntfV(*vp, true, d); changed {
  16600. *vp = v
  16601. }
  16602. }
  16603. func (_ fastpathT) DecMapIntfIntfV(v map[interface{}]interface{}, canChange bool,
  16604. d *Decoder) (_ map[interface{}]interface{}, changed bool) {
  16605. dd, esep := d.d, d.hh.hasElemSeparators()
  16606. containerLen := dd.ReadMapStart()
  16607. if canChange && v == nil {
  16608. xlen := decInferLen(containerLen, d.h.MaxInitLen, 32)
  16609. v = make(map[interface{}]interface{}, xlen)
  16610. changed = true
  16611. }
  16612. if containerLen == 0 {
  16613. dd.ReadMapEnd()
  16614. return v, changed
  16615. }
  16616. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  16617. var mk interface{}
  16618. var mv interface{}
  16619. hasLen := containerLen > 0
  16620. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  16621. if esep {
  16622. dd.ReadMapElemKey()
  16623. }
  16624. mk = nil
  16625. d.decode(&mk)
  16626. if bv, bok := mk.([]byte); bok {
  16627. mk = d.string(bv)
  16628. }
  16629. if esep {
  16630. dd.ReadMapElemValue()
  16631. }
  16632. if dd.TryDecodeAsNil() {
  16633. if d.h.DeleteOnNilMapValue {
  16634. delete(v, mk)
  16635. } else {
  16636. v[mk] = nil
  16637. }
  16638. continue
  16639. }
  16640. if mapGet {
  16641. mv = v[mk]
  16642. } else {
  16643. mv = nil
  16644. }
  16645. d.decode(&mv)
  16646. if v != nil {
  16647. v[mk] = mv
  16648. }
  16649. }
  16650. dd.ReadMapEnd()
  16651. return v, changed
  16652. }
  16653. func (d *Decoder) fastpathDecMapIntfStringR(f *codecFnInfo, rv reflect.Value) {
  16654. if rv.Kind() == reflect.Ptr {
  16655. vp := rv2i(rv).(*map[interface{}]string)
  16656. if v, changed := fastpathTV.DecMapIntfStringV(*vp, true, d); changed {
  16657. *vp = v
  16658. }
  16659. return
  16660. }
  16661. fastpathTV.DecMapIntfStringV(rv2i(rv).(map[interface{}]string), false, d)
  16662. }
  16663. func (f fastpathT) DecMapIntfStringX(vp *map[interface{}]string, d *Decoder) {
  16664. if v, changed := f.DecMapIntfStringV(*vp, true, d); changed {
  16665. *vp = v
  16666. }
  16667. }
  16668. func (_ fastpathT) DecMapIntfStringV(v map[interface{}]string, canChange bool,
  16669. d *Decoder) (_ map[interface{}]string, changed bool) {
  16670. dd, esep := d.d, d.hh.hasElemSeparators()
  16671. containerLen := dd.ReadMapStart()
  16672. if canChange && v == nil {
  16673. xlen := decInferLen(containerLen, d.h.MaxInitLen, 32)
  16674. v = make(map[interface{}]string, xlen)
  16675. changed = true
  16676. }
  16677. if containerLen == 0 {
  16678. dd.ReadMapEnd()
  16679. return v, changed
  16680. }
  16681. var mk interface{}
  16682. var mv string
  16683. hasLen := containerLen > 0
  16684. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  16685. if esep {
  16686. dd.ReadMapElemKey()
  16687. }
  16688. mk = nil
  16689. d.decode(&mk)
  16690. if bv, bok := mk.([]byte); bok {
  16691. mk = d.string(bv)
  16692. }
  16693. if esep {
  16694. dd.ReadMapElemValue()
  16695. }
  16696. if dd.TryDecodeAsNil() {
  16697. if d.h.DeleteOnNilMapValue {
  16698. delete(v, mk)
  16699. } else {
  16700. v[mk] = ""
  16701. }
  16702. continue
  16703. }
  16704. mv = dd.DecodeString()
  16705. if v != nil {
  16706. v[mk] = mv
  16707. }
  16708. }
  16709. dd.ReadMapEnd()
  16710. return v, changed
  16711. }
  16712. func (d *Decoder) fastpathDecMapIntfUintR(f *codecFnInfo, rv reflect.Value) {
  16713. if rv.Kind() == reflect.Ptr {
  16714. vp := rv2i(rv).(*map[interface{}]uint)
  16715. if v, changed := fastpathTV.DecMapIntfUintV(*vp, true, d); changed {
  16716. *vp = v
  16717. }
  16718. return
  16719. }
  16720. fastpathTV.DecMapIntfUintV(rv2i(rv).(map[interface{}]uint), false, d)
  16721. }
  16722. func (f fastpathT) DecMapIntfUintX(vp *map[interface{}]uint, d *Decoder) {
  16723. if v, changed := f.DecMapIntfUintV(*vp, true, d); changed {
  16724. *vp = v
  16725. }
  16726. }
  16727. func (_ fastpathT) DecMapIntfUintV(v map[interface{}]uint, canChange bool,
  16728. d *Decoder) (_ map[interface{}]uint, changed bool) {
  16729. dd, esep := d.d, d.hh.hasElemSeparators()
  16730. containerLen := dd.ReadMapStart()
  16731. if canChange && v == nil {
  16732. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  16733. v = make(map[interface{}]uint, xlen)
  16734. changed = true
  16735. }
  16736. if containerLen == 0 {
  16737. dd.ReadMapEnd()
  16738. return v, changed
  16739. }
  16740. var mk interface{}
  16741. var mv uint
  16742. hasLen := containerLen > 0
  16743. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  16744. if esep {
  16745. dd.ReadMapElemKey()
  16746. }
  16747. mk = nil
  16748. d.decode(&mk)
  16749. if bv, bok := mk.([]byte); bok {
  16750. mk = d.string(bv)
  16751. }
  16752. if esep {
  16753. dd.ReadMapElemValue()
  16754. }
  16755. if dd.TryDecodeAsNil() {
  16756. if d.h.DeleteOnNilMapValue {
  16757. delete(v, mk)
  16758. } else {
  16759. v[mk] = 0
  16760. }
  16761. continue
  16762. }
  16763. mv = uint(dd.DecodeUint(uintBitsize))
  16764. if v != nil {
  16765. v[mk] = mv
  16766. }
  16767. }
  16768. dd.ReadMapEnd()
  16769. return v, changed
  16770. }
  16771. func (d *Decoder) fastpathDecMapIntfUint8R(f *codecFnInfo, rv reflect.Value) {
  16772. if rv.Kind() == reflect.Ptr {
  16773. vp := rv2i(rv).(*map[interface{}]uint8)
  16774. if v, changed := fastpathTV.DecMapIntfUint8V(*vp, true, d); changed {
  16775. *vp = v
  16776. }
  16777. return
  16778. }
  16779. fastpathTV.DecMapIntfUint8V(rv2i(rv).(map[interface{}]uint8), false, d)
  16780. }
  16781. func (f fastpathT) DecMapIntfUint8X(vp *map[interface{}]uint8, d *Decoder) {
  16782. if v, changed := f.DecMapIntfUint8V(*vp, true, d); changed {
  16783. *vp = v
  16784. }
  16785. }
  16786. func (_ fastpathT) DecMapIntfUint8V(v map[interface{}]uint8, canChange bool,
  16787. d *Decoder) (_ map[interface{}]uint8, changed bool) {
  16788. dd, esep := d.d, d.hh.hasElemSeparators()
  16789. containerLen := dd.ReadMapStart()
  16790. if canChange && v == nil {
  16791. xlen := decInferLen(containerLen, d.h.MaxInitLen, 17)
  16792. v = make(map[interface{}]uint8, xlen)
  16793. changed = true
  16794. }
  16795. if containerLen == 0 {
  16796. dd.ReadMapEnd()
  16797. return v, changed
  16798. }
  16799. var mk interface{}
  16800. var mv uint8
  16801. hasLen := containerLen > 0
  16802. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  16803. if esep {
  16804. dd.ReadMapElemKey()
  16805. }
  16806. mk = nil
  16807. d.decode(&mk)
  16808. if bv, bok := mk.([]byte); bok {
  16809. mk = d.string(bv)
  16810. }
  16811. if esep {
  16812. dd.ReadMapElemValue()
  16813. }
  16814. if dd.TryDecodeAsNil() {
  16815. if d.h.DeleteOnNilMapValue {
  16816. delete(v, mk)
  16817. } else {
  16818. v[mk] = 0
  16819. }
  16820. continue
  16821. }
  16822. mv = uint8(dd.DecodeUint(8))
  16823. if v != nil {
  16824. v[mk] = mv
  16825. }
  16826. }
  16827. dd.ReadMapEnd()
  16828. return v, changed
  16829. }
  16830. func (d *Decoder) fastpathDecMapIntfUint16R(f *codecFnInfo, rv reflect.Value) {
  16831. if rv.Kind() == reflect.Ptr {
  16832. vp := rv2i(rv).(*map[interface{}]uint16)
  16833. if v, changed := fastpathTV.DecMapIntfUint16V(*vp, true, d); changed {
  16834. *vp = v
  16835. }
  16836. return
  16837. }
  16838. fastpathTV.DecMapIntfUint16V(rv2i(rv).(map[interface{}]uint16), false, d)
  16839. }
  16840. func (f fastpathT) DecMapIntfUint16X(vp *map[interface{}]uint16, d *Decoder) {
  16841. if v, changed := f.DecMapIntfUint16V(*vp, true, d); changed {
  16842. *vp = v
  16843. }
  16844. }
  16845. func (_ fastpathT) DecMapIntfUint16V(v map[interface{}]uint16, canChange bool,
  16846. d *Decoder) (_ map[interface{}]uint16, changed bool) {
  16847. dd, esep := d.d, d.hh.hasElemSeparators()
  16848. containerLen := dd.ReadMapStart()
  16849. if canChange && v == nil {
  16850. xlen := decInferLen(containerLen, d.h.MaxInitLen, 18)
  16851. v = make(map[interface{}]uint16, xlen)
  16852. changed = true
  16853. }
  16854. if containerLen == 0 {
  16855. dd.ReadMapEnd()
  16856. return v, changed
  16857. }
  16858. var mk interface{}
  16859. var mv uint16
  16860. hasLen := containerLen > 0
  16861. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  16862. if esep {
  16863. dd.ReadMapElemKey()
  16864. }
  16865. mk = nil
  16866. d.decode(&mk)
  16867. if bv, bok := mk.([]byte); bok {
  16868. mk = d.string(bv)
  16869. }
  16870. if esep {
  16871. dd.ReadMapElemValue()
  16872. }
  16873. if dd.TryDecodeAsNil() {
  16874. if d.h.DeleteOnNilMapValue {
  16875. delete(v, mk)
  16876. } else {
  16877. v[mk] = 0
  16878. }
  16879. continue
  16880. }
  16881. mv = uint16(dd.DecodeUint(16))
  16882. if v != nil {
  16883. v[mk] = mv
  16884. }
  16885. }
  16886. dd.ReadMapEnd()
  16887. return v, changed
  16888. }
  16889. func (d *Decoder) fastpathDecMapIntfUint32R(f *codecFnInfo, rv reflect.Value) {
  16890. if rv.Kind() == reflect.Ptr {
  16891. vp := rv2i(rv).(*map[interface{}]uint32)
  16892. if v, changed := fastpathTV.DecMapIntfUint32V(*vp, true, d); changed {
  16893. *vp = v
  16894. }
  16895. return
  16896. }
  16897. fastpathTV.DecMapIntfUint32V(rv2i(rv).(map[interface{}]uint32), false, d)
  16898. }
  16899. func (f fastpathT) DecMapIntfUint32X(vp *map[interface{}]uint32, d *Decoder) {
  16900. if v, changed := f.DecMapIntfUint32V(*vp, true, d); changed {
  16901. *vp = v
  16902. }
  16903. }
  16904. func (_ fastpathT) DecMapIntfUint32V(v map[interface{}]uint32, canChange bool,
  16905. d *Decoder) (_ map[interface{}]uint32, changed bool) {
  16906. dd, esep := d.d, d.hh.hasElemSeparators()
  16907. containerLen := dd.ReadMapStart()
  16908. if canChange && v == nil {
  16909. xlen := decInferLen(containerLen, d.h.MaxInitLen, 20)
  16910. v = make(map[interface{}]uint32, xlen)
  16911. changed = true
  16912. }
  16913. if containerLen == 0 {
  16914. dd.ReadMapEnd()
  16915. return v, changed
  16916. }
  16917. var mk interface{}
  16918. var mv uint32
  16919. hasLen := containerLen > 0
  16920. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  16921. if esep {
  16922. dd.ReadMapElemKey()
  16923. }
  16924. mk = nil
  16925. d.decode(&mk)
  16926. if bv, bok := mk.([]byte); bok {
  16927. mk = d.string(bv)
  16928. }
  16929. if esep {
  16930. dd.ReadMapElemValue()
  16931. }
  16932. if dd.TryDecodeAsNil() {
  16933. if d.h.DeleteOnNilMapValue {
  16934. delete(v, mk)
  16935. } else {
  16936. v[mk] = 0
  16937. }
  16938. continue
  16939. }
  16940. mv = uint32(dd.DecodeUint(32))
  16941. if v != nil {
  16942. v[mk] = mv
  16943. }
  16944. }
  16945. dd.ReadMapEnd()
  16946. return v, changed
  16947. }
  16948. func (d *Decoder) fastpathDecMapIntfUint64R(f *codecFnInfo, rv reflect.Value) {
  16949. if rv.Kind() == reflect.Ptr {
  16950. vp := rv2i(rv).(*map[interface{}]uint64)
  16951. if v, changed := fastpathTV.DecMapIntfUint64V(*vp, true, d); changed {
  16952. *vp = v
  16953. }
  16954. return
  16955. }
  16956. fastpathTV.DecMapIntfUint64V(rv2i(rv).(map[interface{}]uint64), false, d)
  16957. }
  16958. func (f fastpathT) DecMapIntfUint64X(vp *map[interface{}]uint64, d *Decoder) {
  16959. if v, changed := f.DecMapIntfUint64V(*vp, true, d); changed {
  16960. *vp = v
  16961. }
  16962. }
  16963. func (_ fastpathT) DecMapIntfUint64V(v map[interface{}]uint64, canChange bool,
  16964. d *Decoder) (_ map[interface{}]uint64, changed bool) {
  16965. dd, esep := d.d, d.hh.hasElemSeparators()
  16966. containerLen := dd.ReadMapStart()
  16967. if canChange && v == nil {
  16968. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  16969. v = make(map[interface{}]uint64, xlen)
  16970. changed = true
  16971. }
  16972. if containerLen == 0 {
  16973. dd.ReadMapEnd()
  16974. return v, changed
  16975. }
  16976. var mk interface{}
  16977. var mv uint64
  16978. hasLen := containerLen > 0
  16979. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  16980. if esep {
  16981. dd.ReadMapElemKey()
  16982. }
  16983. mk = nil
  16984. d.decode(&mk)
  16985. if bv, bok := mk.([]byte); bok {
  16986. mk = d.string(bv)
  16987. }
  16988. if esep {
  16989. dd.ReadMapElemValue()
  16990. }
  16991. if dd.TryDecodeAsNil() {
  16992. if d.h.DeleteOnNilMapValue {
  16993. delete(v, mk)
  16994. } else {
  16995. v[mk] = 0
  16996. }
  16997. continue
  16998. }
  16999. mv = dd.DecodeUint(64)
  17000. if v != nil {
  17001. v[mk] = mv
  17002. }
  17003. }
  17004. dd.ReadMapEnd()
  17005. return v, changed
  17006. }
  17007. func (d *Decoder) fastpathDecMapIntfUintptrR(f *codecFnInfo, rv reflect.Value) {
  17008. if rv.Kind() == reflect.Ptr {
  17009. vp := rv2i(rv).(*map[interface{}]uintptr)
  17010. if v, changed := fastpathTV.DecMapIntfUintptrV(*vp, true, d); changed {
  17011. *vp = v
  17012. }
  17013. return
  17014. }
  17015. fastpathTV.DecMapIntfUintptrV(rv2i(rv).(map[interface{}]uintptr), false, d)
  17016. }
  17017. func (f fastpathT) DecMapIntfUintptrX(vp *map[interface{}]uintptr, d *Decoder) {
  17018. if v, changed := f.DecMapIntfUintptrV(*vp, true, d); changed {
  17019. *vp = v
  17020. }
  17021. }
  17022. func (_ fastpathT) DecMapIntfUintptrV(v map[interface{}]uintptr, canChange bool,
  17023. d *Decoder) (_ map[interface{}]uintptr, changed bool) {
  17024. dd, esep := d.d, d.hh.hasElemSeparators()
  17025. containerLen := dd.ReadMapStart()
  17026. if canChange && v == nil {
  17027. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  17028. v = make(map[interface{}]uintptr, xlen)
  17029. changed = true
  17030. }
  17031. if containerLen == 0 {
  17032. dd.ReadMapEnd()
  17033. return v, changed
  17034. }
  17035. var mk interface{}
  17036. var mv uintptr
  17037. hasLen := containerLen > 0
  17038. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17039. if esep {
  17040. dd.ReadMapElemKey()
  17041. }
  17042. mk = nil
  17043. d.decode(&mk)
  17044. if bv, bok := mk.([]byte); bok {
  17045. mk = d.string(bv)
  17046. }
  17047. if esep {
  17048. dd.ReadMapElemValue()
  17049. }
  17050. if dd.TryDecodeAsNil() {
  17051. if d.h.DeleteOnNilMapValue {
  17052. delete(v, mk)
  17053. } else {
  17054. v[mk] = 0
  17055. }
  17056. continue
  17057. }
  17058. mv = uintptr(dd.DecodeUint(uintBitsize))
  17059. if v != nil {
  17060. v[mk] = mv
  17061. }
  17062. }
  17063. dd.ReadMapEnd()
  17064. return v, changed
  17065. }
  17066. func (d *Decoder) fastpathDecMapIntfIntR(f *codecFnInfo, rv reflect.Value) {
  17067. if rv.Kind() == reflect.Ptr {
  17068. vp := rv2i(rv).(*map[interface{}]int)
  17069. if v, changed := fastpathTV.DecMapIntfIntV(*vp, true, d); changed {
  17070. *vp = v
  17071. }
  17072. return
  17073. }
  17074. fastpathTV.DecMapIntfIntV(rv2i(rv).(map[interface{}]int), false, d)
  17075. }
  17076. func (f fastpathT) DecMapIntfIntX(vp *map[interface{}]int, d *Decoder) {
  17077. if v, changed := f.DecMapIntfIntV(*vp, true, d); changed {
  17078. *vp = v
  17079. }
  17080. }
  17081. func (_ fastpathT) DecMapIntfIntV(v map[interface{}]int, canChange bool,
  17082. d *Decoder) (_ map[interface{}]int, changed bool) {
  17083. dd, esep := d.d, d.hh.hasElemSeparators()
  17084. containerLen := dd.ReadMapStart()
  17085. if canChange && v == nil {
  17086. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  17087. v = make(map[interface{}]int, xlen)
  17088. changed = true
  17089. }
  17090. if containerLen == 0 {
  17091. dd.ReadMapEnd()
  17092. return v, changed
  17093. }
  17094. var mk interface{}
  17095. var mv int
  17096. hasLen := containerLen > 0
  17097. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17098. if esep {
  17099. dd.ReadMapElemKey()
  17100. }
  17101. mk = nil
  17102. d.decode(&mk)
  17103. if bv, bok := mk.([]byte); bok {
  17104. mk = d.string(bv)
  17105. }
  17106. if esep {
  17107. dd.ReadMapElemValue()
  17108. }
  17109. if dd.TryDecodeAsNil() {
  17110. if d.h.DeleteOnNilMapValue {
  17111. delete(v, mk)
  17112. } else {
  17113. v[mk] = 0
  17114. }
  17115. continue
  17116. }
  17117. mv = int(dd.DecodeInt(intBitsize))
  17118. if v != nil {
  17119. v[mk] = mv
  17120. }
  17121. }
  17122. dd.ReadMapEnd()
  17123. return v, changed
  17124. }
  17125. func (d *Decoder) fastpathDecMapIntfInt8R(f *codecFnInfo, rv reflect.Value) {
  17126. if rv.Kind() == reflect.Ptr {
  17127. vp := rv2i(rv).(*map[interface{}]int8)
  17128. if v, changed := fastpathTV.DecMapIntfInt8V(*vp, true, d); changed {
  17129. *vp = v
  17130. }
  17131. return
  17132. }
  17133. fastpathTV.DecMapIntfInt8V(rv2i(rv).(map[interface{}]int8), false, d)
  17134. }
  17135. func (f fastpathT) DecMapIntfInt8X(vp *map[interface{}]int8, d *Decoder) {
  17136. if v, changed := f.DecMapIntfInt8V(*vp, true, d); changed {
  17137. *vp = v
  17138. }
  17139. }
  17140. func (_ fastpathT) DecMapIntfInt8V(v map[interface{}]int8, canChange bool,
  17141. d *Decoder) (_ map[interface{}]int8, changed bool) {
  17142. dd, esep := d.d, d.hh.hasElemSeparators()
  17143. containerLen := dd.ReadMapStart()
  17144. if canChange && v == nil {
  17145. xlen := decInferLen(containerLen, d.h.MaxInitLen, 17)
  17146. v = make(map[interface{}]int8, xlen)
  17147. changed = true
  17148. }
  17149. if containerLen == 0 {
  17150. dd.ReadMapEnd()
  17151. return v, changed
  17152. }
  17153. var mk interface{}
  17154. var mv int8
  17155. hasLen := containerLen > 0
  17156. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17157. if esep {
  17158. dd.ReadMapElemKey()
  17159. }
  17160. mk = nil
  17161. d.decode(&mk)
  17162. if bv, bok := mk.([]byte); bok {
  17163. mk = d.string(bv)
  17164. }
  17165. if esep {
  17166. dd.ReadMapElemValue()
  17167. }
  17168. if dd.TryDecodeAsNil() {
  17169. if d.h.DeleteOnNilMapValue {
  17170. delete(v, mk)
  17171. } else {
  17172. v[mk] = 0
  17173. }
  17174. continue
  17175. }
  17176. mv = int8(dd.DecodeInt(8))
  17177. if v != nil {
  17178. v[mk] = mv
  17179. }
  17180. }
  17181. dd.ReadMapEnd()
  17182. return v, changed
  17183. }
  17184. func (d *Decoder) fastpathDecMapIntfInt16R(f *codecFnInfo, rv reflect.Value) {
  17185. if rv.Kind() == reflect.Ptr {
  17186. vp := rv2i(rv).(*map[interface{}]int16)
  17187. if v, changed := fastpathTV.DecMapIntfInt16V(*vp, true, d); changed {
  17188. *vp = v
  17189. }
  17190. return
  17191. }
  17192. fastpathTV.DecMapIntfInt16V(rv2i(rv).(map[interface{}]int16), false, d)
  17193. }
  17194. func (f fastpathT) DecMapIntfInt16X(vp *map[interface{}]int16, d *Decoder) {
  17195. if v, changed := f.DecMapIntfInt16V(*vp, true, d); changed {
  17196. *vp = v
  17197. }
  17198. }
  17199. func (_ fastpathT) DecMapIntfInt16V(v map[interface{}]int16, canChange bool,
  17200. d *Decoder) (_ map[interface{}]int16, changed bool) {
  17201. dd, esep := d.d, d.hh.hasElemSeparators()
  17202. containerLen := dd.ReadMapStart()
  17203. if canChange && v == nil {
  17204. xlen := decInferLen(containerLen, d.h.MaxInitLen, 18)
  17205. v = make(map[interface{}]int16, xlen)
  17206. changed = true
  17207. }
  17208. if containerLen == 0 {
  17209. dd.ReadMapEnd()
  17210. return v, changed
  17211. }
  17212. var mk interface{}
  17213. var mv int16
  17214. hasLen := containerLen > 0
  17215. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17216. if esep {
  17217. dd.ReadMapElemKey()
  17218. }
  17219. mk = nil
  17220. d.decode(&mk)
  17221. if bv, bok := mk.([]byte); bok {
  17222. mk = d.string(bv)
  17223. }
  17224. if esep {
  17225. dd.ReadMapElemValue()
  17226. }
  17227. if dd.TryDecodeAsNil() {
  17228. if d.h.DeleteOnNilMapValue {
  17229. delete(v, mk)
  17230. } else {
  17231. v[mk] = 0
  17232. }
  17233. continue
  17234. }
  17235. mv = int16(dd.DecodeInt(16))
  17236. if v != nil {
  17237. v[mk] = mv
  17238. }
  17239. }
  17240. dd.ReadMapEnd()
  17241. return v, changed
  17242. }
  17243. func (d *Decoder) fastpathDecMapIntfInt32R(f *codecFnInfo, rv reflect.Value) {
  17244. if rv.Kind() == reflect.Ptr {
  17245. vp := rv2i(rv).(*map[interface{}]int32)
  17246. if v, changed := fastpathTV.DecMapIntfInt32V(*vp, true, d); changed {
  17247. *vp = v
  17248. }
  17249. return
  17250. }
  17251. fastpathTV.DecMapIntfInt32V(rv2i(rv).(map[interface{}]int32), false, d)
  17252. }
  17253. func (f fastpathT) DecMapIntfInt32X(vp *map[interface{}]int32, d *Decoder) {
  17254. if v, changed := f.DecMapIntfInt32V(*vp, true, d); changed {
  17255. *vp = v
  17256. }
  17257. }
  17258. func (_ fastpathT) DecMapIntfInt32V(v map[interface{}]int32, canChange bool,
  17259. d *Decoder) (_ map[interface{}]int32, changed bool) {
  17260. dd, esep := d.d, d.hh.hasElemSeparators()
  17261. containerLen := dd.ReadMapStart()
  17262. if canChange && v == nil {
  17263. xlen := decInferLen(containerLen, d.h.MaxInitLen, 20)
  17264. v = make(map[interface{}]int32, xlen)
  17265. changed = true
  17266. }
  17267. if containerLen == 0 {
  17268. dd.ReadMapEnd()
  17269. return v, changed
  17270. }
  17271. var mk interface{}
  17272. var mv int32
  17273. hasLen := containerLen > 0
  17274. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17275. if esep {
  17276. dd.ReadMapElemKey()
  17277. }
  17278. mk = nil
  17279. d.decode(&mk)
  17280. if bv, bok := mk.([]byte); bok {
  17281. mk = d.string(bv)
  17282. }
  17283. if esep {
  17284. dd.ReadMapElemValue()
  17285. }
  17286. if dd.TryDecodeAsNil() {
  17287. if d.h.DeleteOnNilMapValue {
  17288. delete(v, mk)
  17289. } else {
  17290. v[mk] = 0
  17291. }
  17292. continue
  17293. }
  17294. mv = int32(dd.DecodeInt(32))
  17295. if v != nil {
  17296. v[mk] = mv
  17297. }
  17298. }
  17299. dd.ReadMapEnd()
  17300. return v, changed
  17301. }
  17302. func (d *Decoder) fastpathDecMapIntfInt64R(f *codecFnInfo, rv reflect.Value) {
  17303. if rv.Kind() == reflect.Ptr {
  17304. vp := rv2i(rv).(*map[interface{}]int64)
  17305. if v, changed := fastpathTV.DecMapIntfInt64V(*vp, true, d); changed {
  17306. *vp = v
  17307. }
  17308. return
  17309. }
  17310. fastpathTV.DecMapIntfInt64V(rv2i(rv).(map[interface{}]int64), false, d)
  17311. }
  17312. func (f fastpathT) DecMapIntfInt64X(vp *map[interface{}]int64, d *Decoder) {
  17313. if v, changed := f.DecMapIntfInt64V(*vp, true, d); changed {
  17314. *vp = v
  17315. }
  17316. }
  17317. func (_ fastpathT) DecMapIntfInt64V(v map[interface{}]int64, canChange bool,
  17318. d *Decoder) (_ map[interface{}]int64, changed bool) {
  17319. dd, esep := d.d, d.hh.hasElemSeparators()
  17320. containerLen := dd.ReadMapStart()
  17321. if canChange && v == nil {
  17322. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  17323. v = make(map[interface{}]int64, xlen)
  17324. changed = true
  17325. }
  17326. if containerLen == 0 {
  17327. dd.ReadMapEnd()
  17328. return v, changed
  17329. }
  17330. var mk interface{}
  17331. var mv int64
  17332. hasLen := containerLen > 0
  17333. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17334. if esep {
  17335. dd.ReadMapElemKey()
  17336. }
  17337. mk = nil
  17338. d.decode(&mk)
  17339. if bv, bok := mk.([]byte); bok {
  17340. mk = d.string(bv)
  17341. }
  17342. if esep {
  17343. dd.ReadMapElemValue()
  17344. }
  17345. if dd.TryDecodeAsNil() {
  17346. if d.h.DeleteOnNilMapValue {
  17347. delete(v, mk)
  17348. } else {
  17349. v[mk] = 0
  17350. }
  17351. continue
  17352. }
  17353. mv = dd.DecodeInt(64)
  17354. if v != nil {
  17355. v[mk] = mv
  17356. }
  17357. }
  17358. dd.ReadMapEnd()
  17359. return v, changed
  17360. }
  17361. func (d *Decoder) fastpathDecMapIntfFloat32R(f *codecFnInfo, rv reflect.Value) {
  17362. if rv.Kind() == reflect.Ptr {
  17363. vp := rv2i(rv).(*map[interface{}]float32)
  17364. if v, changed := fastpathTV.DecMapIntfFloat32V(*vp, true, d); changed {
  17365. *vp = v
  17366. }
  17367. return
  17368. }
  17369. fastpathTV.DecMapIntfFloat32V(rv2i(rv).(map[interface{}]float32), false, d)
  17370. }
  17371. func (f fastpathT) DecMapIntfFloat32X(vp *map[interface{}]float32, d *Decoder) {
  17372. if v, changed := f.DecMapIntfFloat32V(*vp, true, d); changed {
  17373. *vp = v
  17374. }
  17375. }
  17376. func (_ fastpathT) DecMapIntfFloat32V(v map[interface{}]float32, canChange bool,
  17377. d *Decoder) (_ map[interface{}]float32, changed bool) {
  17378. dd, esep := d.d, d.hh.hasElemSeparators()
  17379. containerLen := dd.ReadMapStart()
  17380. if canChange && v == nil {
  17381. xlen := decInferLen(containerLen, d.h.MaxInitLen, 20)
  17382. v = make(map[interface{}]float32, xlen)
  17383. changed = true
  17384. }
  17385. if containerLen == 0 {
  17386. dd.ReadMapEnd()
  17387. return v, changed
  17388. }
  17389. var mk interface{}
  17390. var mv float32
  17391. hasLen := containerLen > 0
  17392. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17393. if esep {
  17394. dd.ReadMapElemKey()
  17395. }
  17396. mk = nil
  17397. d.decode(&mk)
  17398. if bv, bok := mk.([]byte); bok {
  17399. mk = d.string(bv)
  17400. }
  17401. if esep {
  17402. dd.ReadMapElemValue()
  17403. }
  17404. if dd.TryDecodeAsNil() {
  17405. if d.h.DeleteOnNilMapValue {
  17406. delete(v, mk)
  17407. } else {
  17408. v[mk] = 0
  17409. }
  17410. continue
  17411. }
  17412. mv = float32(dd.DecodeFloat(true))
  17413. if v != nil {
  17414. v[mk] = mv
  17415. }
  17416. }
  17417. dd.ReadMapEnd()
  17418. return v, changed
  17419. }
  17420. func (d *Decoder) fastpathDecMapIntfFloat64R(f *codecFnInfo, rv reflect.Value) {
  17421. if rv.Kind() == reflect.Ptr {
  17422. vp := rv2i(rv).(*map[interface{}]float64)
  17423. if v, changed := fastpathTV.DecMapIntfFloat64V(*vp, true, d); changed {
  17424. *vp = v
  17425. }
  17426. return
  17427. }
  17428. fastpathTV.DecMapIntfFloat64V(rv2i(rv).(map[interface{}]float64), false, d)
  17429. }
  17430. func (f fastpathT) DecMapIntfFloat64X(vp *map[interface{}]float64, d *Decoder) {
  17431. if v, changed := f.DecMapIntfFloat64V(*vp, true, d); changed {
  17432. *vp = v
  17433. }
  17434. }
  17435. func (_ fastpathT) DecMapIntfFloat64V(v map[interface{}]float64, canChange bool,
  17436. d *Decoder) (_ map[interface{}]float64, changed bool) {
  17437. dd, esep := d.d, d.hh.hasElemSeparators()
  17438. containerLen := dd.ReadMapStart()
  17439. if canChange && v == nil {
  17440. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  17441. v = make(map[interface{}]float64, xlen)
  17442. changed = true
  17443. }
  17444. if containerLen == 0 {
  17445. dd.ReadMapEnd()
  17446. return v, changed
  17447. }
  17448. var mk interface{}
  17449. var mv float64
  17450. hasLen := containerLen > 0
  17451. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17452. if esep {
  17453. dd.ReadMapElemKey()
  17454. }
  17455. mk = nil
  17456. d.decode(&mk)
  17457. if bv, bok := mk.([]byte); bok {
  17458. mk = d.string(bv)
  17459. }
  17460. if esep {
  17461. dd.ReadMapElemValue()
  17462. }
  17463. if dd.TryDecodeAsNil() {
  17464. if d.h.DeleteOnNilMapValue {
  17465. delete(v, mk)
  17466. } else {
  17467. v[mk] = 0
  17468. }
  17469. continue
  17470. }
  17471. mv = dd.DecodeFloat(false)
  17472. if v != nil {
  17473. v[mk] = mv
  17474. }
  17475. }
  17476. dd.ReadMapEnd()
  17477. return v, changed
  17478. }
  17479. func (d *Decoder) fastpathDecMapIntfBoolR(f *codecFnInfo, rv reflect.Value) {
  17480. if rv.Kind() == reflect.Ptr {
  17481. vp := rv2i(rv).(*map[interface{}]bool)
  17482. if v, changed := fastpathTV.DecMapIntfBoolV(*vp, true, d); changed {
  17483. *vp = v
  17484. }
  17485. return
  17486. }
  17487. fastpathTV.DecMapIntfBoolV(rv2i(rv).(map[interface{}]bool), false, d)
  17488. }
  17489. func (f fastpathT) DecMapIntfBoolX(vp *map[interface{}]bool, d *Decoder) {
  17490. if v, changed := f.DecMapIntfBoolV(*vp, true, d); changed {
  17491. *vp = v
  17492. }
  17493. }
  17494. func (_ fastpathT) DecMapIntfBoolV(v map[interface{}]bool, canChange bool,
  17495. d *Decoder) (_ map[interface{}]bool, changed bool) {
  17496. dd, esep := d.d, d.hh.hasElemSeparators()
  17497. containerLen := dd.ReadMapStart()
  17498. if canChange && v == nil {
  17499. xlen := decInferLen(containerLen, d.h.MaxInitLen, 17)
  17500. v = make(map[interface{}]bool, xlen)
  17501. changed = true
  17502. }
  17503. if containerLen == 0 {
  17504. dd.ReadMapEnd()
  17505. return v, changed
  17506. }
  17507. var mk interface{}
  17508. var mv bool
  17509. hasLen := containerLen > 0
  17510. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17511. if esep {
  17512. dd.ReadMapElemKey()
  17513. }
  17514. mk = nil
  17515. d.decode(&mk)
  17516. if bv, bok := mk.([]byte); bok {
  17517. mk = d.string(bv)
  17518. }
  17519. if esep {
  17520. dd.ReadMapElemValue()
  17521. }
  17522. if dd.TryDecodeAsNil() {
  17523. if d.h.DeleteOnNilMapValue {
  17524. delete(v, mk)
  17525. } else {
  17526. v[mk] = false
  17527. }
  17528. continue
  17529. }
  17530. mv = dd.DecodeBool()
  17531. if v != nil {
  17532. v[mk] = mv
  17533. }
  17534. }
  17535. dd.ReadMapEnd()
  17536. return v, changed
  17537. }
  17538. func (d *Decoder) fastpathDecMapStringIntfR(f *codecFnInfo, rv reflect.Value) {
  17539. if rv.Kind() == reflect.Ptr {
  17540. vp := rv2i(rv).(*map[string]interface{})
  17541. if v, changed := fastpathTV.DecMapStringIntfV(*vp, true, d); changed {
  17542. *vp = v
  17543. }
  17544. return
  17545. }
  17546. fastpathTV.DecMapStringIntfV(rv2i(rv).(map[string]interface{}), false, d)
  17547. }
  17548. func (f fastpathT) DecMapStringIntfX(vp *map[string]interface{}, d *Decoder) {
  17549. if v, changed := f.DecMapStringIntfV(*vp, true, d); changed {
  17550. *vp = v
  17551. }
  17552. }
  17553. func (_ fastpathT) DecMapStringIntfV(v map[string]interface{}, canChange bool,
  17554. d *Decoder) (_ map[string]interface{}, changed bool) {
  17555. dd, esep := d.d, d.hh.hasElemSeparators()
  17556. containerLen := dd.ReadMapStart()
  17557. if canChange && v == nil {
  17558. xlen := decInferLen(containerLen, d.h.MaxInitLen, 32)
  17559. v = make(map[string]interface{}, xlen)
  17560. changed = true
  17561. }
  17562. if containerLen == 0 {
  17563. dd.ReadMapEnd()
  17564. return v, changed
  17565. }
  17566. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  17567. var mk string
  17568. var mv interface{}
  17569. hasLen := containerLen > 0
  17570. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17571. if esep {
  17572. dd.ReadMapElemKey()
  17573. }
  17574. mk = dd.DecodeString()
  17575. if esep {
  17576. dd.ReadMapElemValue()
  17577. }
  17578. if dd.TryDecodeAsNil() {
  17579. if d.h.DeleteOnNilMapValue {
  17580. delete(v, mk)
  17581. } else {
  17582. v[mk] = nil
  17583. }
  17584. continue
  17585. }
  17586. if mapGet {
  17587. mv = v[mk]
  17588. } else {
  17589. mv = nil
  17590. }
  17591. d.decode(&mv)
  17592. if v != nil {
  17593. v[mk] = mv
  17594. }
  17595. }
  17596. dd.ReadMapEnd()
  17597. return v, changed
  17598. }
  17599. func (d *Decoder) fastpathDecMapStringStringR(f *codecFnInfo, rv reflect.Value) {
  17600. if rv.Kind() == reflect.Ptr {
  17601. vp := rv2i(rv).(*map[string]string)
  17602. if v, changed := fastpathTV.DecMapStringStringV(*vp, true, d); changed {
  17603. *vp = v
  17604. }
  17605. return
  17606. }
  17607. fastpathTV.DecMapStringStringV(rv2i(rv).(map[string]string), false, d)
  17608. }
  17609. func (f fastpathT) DecMapStringStringX(vp *map[string]string, d *Decoder) {
  17610. if v, changed := f.DecMapStringStringV(*vp, true, d); changed {
  17611. *vp = v
  17612. }
  17613. }
  17614. func (_ fastpathT) DecMapStringStringV(v map[string]string, canChange bool,
  17615. d *Decoder) (_ map[string]string, changed bool) {
  17616. dd, esep := d.d, d.hh.hasElemSeparators()
  17617. containerLen := dd.ReadMapStart()
  17618. if canChange && v == nil {
  17619. xlen := decInferLen(containerLen, d.h.MaxInitLen, 32)
  17620. v = make(map[string]string, xlen)
  17621. changed = true
  17622. }
  17623. if containerLen == 0 {
  17624. dd.ReadMapEnd()
  17625. return v, changed
  17626. }
  17627. var mk string
  17628. var mv string
  17629. hasLen := containerLen > 0
  17630. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17631. if esep {
  17632. dd.ReadMapElemKey()
  17633. }
  17634. mk = dd.DecodeString()
  17635. if esep {
  17636. dd.ReadMapElemValue()
  17637. }
  17638. if dd.TryDecodeAsNil() {
  17639. if d.h.DeleteOnNilMapValue {
  17640. delete(v, mk)
  17641. } else {
  17642. v[mk] = ""
  17643. }
  17644. continue
  17645. }
  17646. mv = dd.DecodeString()
  17647. if v != nil {
  17648. v[mk] = mv
  17649. }
  17650. }
  17651. dd.ReadMapEnd()
  17652. return v, changed
  17653. }
  17654. func (d *Decoder) fastpathDecMapStringUintR(f *codecFnInfo, rv reflect.Value) {
  17655. if rv.Kind() == reflect.Ptr {
  17656. vp := rv2i(rv).(*map[string]uint)
  17657. if v, changed := fastpathTV.DecMapStringUintV(*vp, true, d); changed {
  17658. *vp = v
  17659. }
  17660. return
  17661. }
  17662. fastpathTV.DecMapStringUintV(rv2i(rv).(map[string]uint), false, d)
  17663. }
  17664. func (f fastpathT) DecMapStringUintX(vp *map[string]uint, d *Decoder) {
  17665. if v, changed := f.DecMapStringUintV(*vp, true, d); changed {
  17666. *vp = v
  17667. }
  17668. }
  17669. func (_ fastpathT) DecMapStringUintV(v map[string]uint, canChange bool,
  17670. d *Decoder) (_ map[string]uint, changed bool) {
  17671. dd, esep := d.d, d.hh.hasElemSeparators()
  17672. containerLen := dd.ReadMapStart()
  17673. if canChange && v == nil {
  17674. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  17675. v = make(map[string]uint, xlen)
  17676. changed = true
  17677. }
  17678. if containerLen == 0 {
  17679. dd.ReadMapEnd()
  17680. return v, changed
  17681. }
  17682. var mk string
  17683. var mv uint
  17684. hasLen := containerLen > 0
  17685. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17686. if esep {
  17687. dd.ReadMapElemKey()
  17688. }
  17689. mk = dd.DecodeString()
  17690. if esep {
  17691. dd.ReadMapElemValue()
  17692. }
  17693. if dd.TryDecodeAsNil() {
  17694. if d.h.DeleteOnNilMapValue {
  17695. delete(v, mk)
  17696. } else {
  17697. v[mk] = 0
  17698. }
  17699. continue
  17700. }
  17701. mv = uint(dd.DecodeUint(uintBitsize))
  17702. if v != nil {
  17703. v[mk] = mv
  17704. }
  17705. }
  17706. dd.ReadMapEnd()
  17707. return v, changed
  17708. }
  17709. func (d *Decoder) fastpathDecMapStringUint8R(f *codecFnInfo, rv reflect.Value) {
  17710. if rv.Kind() == reflect.Ptr {
  17711. vp := rv2i(rv).(*map[string]uint8)
  17712. if v, changed := fastpathTV.DecMapStringUint8V(*vp, true, d); changed {
  17713. *vp = v
  17714. }
  17715. return
  17716. }
  17717. fastpathTV.DecMapStringUint8V(rv2i(rv).(map[string]uint8), false, d)
  17718. }
  17719. func (f fastpathT) DecMapStringUint8X(vp *map[string]uint8, d *Decoder) {
  17720. if v, changed := f.DecMapStringUint8V(*vp, true, d); changed {
  17721. *vp = v
  17722. }
  17723. }
  17724. func (_ fastpathT) DecMapStringUint8V(v map[string]uint8, canChange bool,
  17725. d *Decoder) (_ map[string]uint8, changed bool) {
  17726. dd, esep := d.d, d.hh.hasElemSeparators()
  17727. containerLen := dd.ReadMapStart()
  17728. if canChange && v == nil {
  17729. xlen := decInferLen(containerLen, d.h.MaxInitLen, 17)
  17730. v = make(map[string]uint8, xlen)
  17731. changed = true
  17732. }
  17733. if containerLen == 0 {
  17734. dd.ReadMapEnd()
  17735. return v, changed
  17736. }
  17737. var mk string
  17738. var mv uint8
  17739. hasLen := containerLen > 0
  17740. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17741. if esep {
  17742. dd.ReadMapElemKey()
  17743. }
  17744. mk = dd.DecodeString()
  17745. if esep {
  17746. dd.ReadMapElemValue()
  17747. }
  17748. if dd.TryDecodeAsNil() {
  17749. if d.h.DeleteOnNilMapValue {
  17750. delete(v, mk)
  17751. } else {
  17752. v[mk] = 0
  17753. }
  17754. continue
  17755. }
  17756. mv = uint8(dd.DecodeUint(8))
  17757. if v != nil {
  17758. v[mk] = mv
  17759. }
  17760. }
  17761. dd.ReadMapEnd()
  17762. return v, changed
  17763. }
  17764. func (d *Decoder) fastpathDecMapStringUint16R(f *codecFnInfo, rv reflect.Value) {
  17765. if rv.Kind() == reflect.Ptr {
  17766. vp := rv2i(rv).(*map[string]uint16)
  17767. if v, changed := fastpathTV.DecMapStringUint16V(*vp, true, d); changed {
  17768. *vp = v
  17769. }
  17770. return
  17771. }
  17772. fastpathTV.DecMapStringUint16V(rv2i(rv).(map[string]uint16), false, d)
  17773. }
  17774. func (f fastpathT) DecMapStringUint16X(vp *map[string]uint16, d *Decoder) {
  17775. if v, changed := f.DecMapStringUint16V(*vp, true, d); changed {
  17776. *vp = v
  17777. }
  17778. }
  17779. func (_ fastpathT) DecMapStringUint16V(v map[string]uint16, canChange bool,
  17780. d *Decoder) (_ map[string]uint16, changed bool) {
  17781. dd, esep := d.d, d.hh.hasElemSeparators()
  17782. containerLen := dd.ReadMapStart()
  17783. if canChange && v == nil {
  17784. xlen := decInferLen(containerLen, d.h.MaxInitLen, 18)
  17785. v = make(map[string]uint16, xlen)
  17786. changed = true
  17787. }
  17788. if containerLen == 0 {
  17789. dd.ReadMapEnd()
  17790. return v, changed
  17791. }
  17792. var mk string
  17793. var mv uint16
  17794. hasLen := containerLen > 0
  17795. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17796. if esep {
  17797. dd.ReadMapElemKey()
  17798. }
  17799. mk = dd.DecodeString()
  17800. if esep {
  17801. dd.ReadMapElemValue()
  17802. }
  17803. if dd.TryDecodeAsNil() {
  17804. if d.h.DeleteOnNilMapValue {
  17805. delete(v, mk)
  17806. } else {
  17807. v[mk] = 0
  17808. }
  17809. continue
  17810. }
  17811. mv = uint16(dd.DecodeUint(16))
  17812. if v != nil {
  17813. v[mk] = mv
  17814. }
  17815. }
  17816. dd.ReadMapEnd()
  17817. return v, changed
  17818. }
  17819. func (d *Decoder) fastpathDecMapStringUint32R(f *codecFnInfo, rv reflect.Value) {
  17820. if rv.Kind() == reflect.Ptr {
  17821. vp := rv2i(rv).(*map[string]uint32)
  17822. if v, changed := fastpathTV.DecMapStringUint32V(*vp, true, d); changed {
  17823. *vp = v
  17824. }
  17825. return
  17826. }
  17827. fastpathTV.DecMapStringUint32V(rv2i(rv).(map[string]uint32), false, d)
  17828. }
  17829. func (f fastpathT) DecMapStringUint32X(vp *map[string]uint32, d *Decoder) {
  17830. if v, changed := f.DecMapStringUint32V(*vp, true, d); changed {
  17831. *vp = v
  17832. }
  17833. }
  17834. func (_ fastpathT) DecMapStringUint32V(v map[string]uint32, canChange bool,
  17835. d *Decoder) (_ map[string]uint32, changed bool) {
  17836. dd, esep := d.d, d.hh.hasElemSeparators()
  17837. containerLen := dd.ReadMapStart()
  17838. if canChange && v == nil {
  17839. xlen := decInferLen(containerLen, d.h.MaxInitLen, 20)
  17840. v = make(map[string]uint32, xlen)
  17841. changed = true
  17842. }
  17843. if containerLen == 0 {
  17844. dd.ReadMapEnd()
  17845. return v, changed
  17846. }
  17847. var mk string
  17848. var mv uint32
  17849. hasLen := containerLen > 0
  17850. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17851. if esep {
  17852. dd.ReadMapElemKey()
  17853. }
  17854. mk = dd.DecodeString()
  17855. if esep {
  17856. dd.ReadMapElemValue()
  17857. }
  17858. if dd.TryDecodeAsNil() {
  17859. if d.h.DeleteOnNilMapValue {
  17860. delete(v, mk)
  17861. } else {
  17862. v[mk] = 0
  17863. }
  17864. continue
  17865. }
  17866. mv = uint32(dd.DecodeUint(32))
  17867. if v != nil {
  17868. v[mk] = mv
  17869. }
  17870. }
  17871. dd.ReadMapEnd()
  17872. return v, changed
  17873. }
  17874. func (d *Decoder) fastpathDecMapStringUint64R(f *codecFnInfo, rv reflect.Value) {
  17875. if rv.Kind() == reflect.Ptr {
  17876. vp := rv2i(rv).(*map[string]uint64)
  17877. if v, changed := fastpathTV.DecMapStringUint64V(*vp, true, d); changed {
  17878. *vp = v
  17879. }
  17880. return
  17881. }
  17882. fastpathTV.DecMapStringUint64V(rv2i(rv).(map[string]uint64), false, d)
  17883. }
  17884. func (f fastpathT) DecMapStringUint64X(vp *map[string]uint64, d *Decoder) {
  17885. if v, changed := f.DecMapStringUint64V(*vp, true, d); changed {
  17886. *vp = v
  17887. }
  17888. }
  17889. func (_ fastpathT) DecMapStringUint64V(v map[string]uint64, canChange bool,
  17890. d *Decoder) (_ map[string]uint64, changed bool) {
  17891. dd, esep := d.d, d.hh.hasElemSeparators()
  17892. containerLen := dd.ReadMapStart()
  17893. if canChange && v == nil {
  17894. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  17895. v = make(map[string]uint64, xlen)
  17896. changed = true
  17897. }
  17898. if containerLen == 0 {
  17899. dd.ReadMapEnd()
  17900. return v, changed
  17901. }
  17902. var mk string
  17903. var mv uint64
  17904. hasLen := containerLen > 0
  17905. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17906. if esep {
  17907. dd.ReadMapElemKey()
  17908. }
  17909. mk = dd.DecodeString()
  17910. if esep {
  17911. dd.ReadMapElemValue()
  17912. }
  17913. if dd.TryDecodeAsNil() {
  17914. if d.h.DeleteOnNilMapValue {
  17915. delete(v, mk)
  17916. } else {
  17917. v[mk] = 0
  17918. }
  17919. continue
  17920. }
  17921. mv = dd.DecodeUint(64)
  17922. if v != nil {
  17923. v[mk] = mv
  17924. }
  17925. }
  17926. dd.ReadMapEnd()
  17927. return v, changed
  17928. }
  17929. func (d *Decoder) fastpathDecMapStringUintptrR(f *codecFnInfo, rv reflect.Value) {
  17930. if rv.Kind() == reflect.Ptr {
  17931. vp := rv2i(rv).(*map[string]uintptr)
  17932. if v, changed := fastpathTV.DecMapStringUintptrV(*vp, true, d); changed {
  17933. *vp = v
  17934. }
  17935. return
  17936. }
  17937. fastpathTV.DecMapStringUintptrV(rv2i(rv).(map[string]uintptr), false, d)
  17938. }
  17939. func (f fastpathT) DecMapStringUintptrX(vp *map[string]uintptr, d *Decoder) {
  17940. if v, changed := f.DecMapStringUintptrV(*vp, true, d); changed {
  17941. *vp = v
  17942. }
  17943. }
  17944. func (_ fastpathT) DecMapStringUintptrV(v map[string]uintptr, canChange bool,
  17945. d *Decoder) (_ map[string]uintptr, changed bool) {
  17946. dd, esep := d.d, d.hh.hasElemSeparators()
  17947. containerLen := dd.ReadMapStart()
  17948. if canChange && v == nil {
  17949. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  17950. v = make(map[string]uintptr, xlen)
  17951. changed = true
  17952. }
  17953. if containerLen == 0 {
  17954. dd.ReadMapEnd()
  17955. return v, changed
  17956. }
  17957. var mk string
  17958. var mv uintptr
  17959. hasLen := containerLen > 0
  17960. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17961. if esep {
  17962. dd.ReadMapElemKey()
  17963. }
  17964. mk = dd.DecodeString()
  17965. if esep {
  17966. dd.ReadMapElemValue()
  17967. }
  17968. if dd.TryDecodeAsNil() {
  17969. if d.h.DeleteOnNilMapValue {
  17970. delete(v, mk)
  17971. } else {
  17972. v[mk] = 0
  17973. }
  17974. continue
  17975. }
  17976. mv = uintptr(dd.DecodeUint(uintBitsize))
  17977. if v != nil {
  17978. v[mk] = mv
  17979. }
  17980. }
  17981. dd.ReadMapEnd()
  17982. return v, changed
  17983. }
  17984. func (d *Decoder) fastpathDecMapStringIntR(f *codecFnInfo, rv reflect.Value) {
  17985. if rv.Kind() == reflect.Ptr {
  17986. vp := rv2i(rv).(*map[string]int)
  17987. if v, changed := fastpathTV.DecMapStringIntV(*vp, true, d); changed {
  17988. *vp = v
  17989. }
  17990. return
  17991. }
  17992. fastpathTV.DecMapStringIntV(rv2i(rv).(map[string]int), false, d)
  17993. }
  17994. func (f fastpathT) DecMapStringIntX(vp *map[string]int, d *Decoder) {
  17995. if v, changed := f.DecMapStringIntV(*vp, true, d); changed {
  17996. *vp = v
  17997. }
  17998. }
  17999. func (_ fastpathT) DecMapStringIntV(v map[string]int, canChange bool,
  18000. d *Decoder) (_ map[string]int, changed bool) {
  18001. dd, esep := d.d, d.hh.hasElemSeparators()
  18002. containerLen := dd.ReadMapStart()
  18003. if canChange && v == nil {
  18004. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  18005. v = make(map[string]int, xlen)
  18006. changed = true
  18007. }
  18008. if containerLen == 0 {
  18009. dd.ReadMapEnd()
  18010. return v, changed
  18011. }
  18012. var mk string
  18013. var mv int
  18014. hasLen := containerLen > 0
  18015. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18016. if esep {
  18017. dd.ReadMapElemKey()
  18018. }
  18019. mk = dd.DecodeString()
  18020. if esep {
  18021. dd.ReadMapElemValue()
  18022. }
  18023. if dd.TryDecodeAsNil() {
  18024. if d.h.DeleteOnNilMapValue {
  18025. delete(v, mk)
  18026. } else {
  18027. v[mk] = 0
  18028. }
  18029. continue
  18030. }
  18031. mv = int(dd.DecodeInt(intBitsize))
  18032. if v != nil {
  18033. v[mk] = mv
  18034. }
  18035. }
  18036. dd.ReadMapEnd()
  18037. return v, changed
  18038. }
  18039. func (d *Decoder) fastpathDecMapStringInt8R(f *codecFnInfo, rv reflect.Value) {
  18040. if rv.Kind() == reflect.Ptr {
  18041. vp := rv2i(rv).(*map[string]int8)
  18042. if v, changed := fastpathTV.DecMapStringInt8V(*vp, true, d); changed {
  18043. *vp = v
  18044. }
  18045. return
  18046. }
  18047. fastpathTV.DecMapStringInt8V(rv2i(rv).(map[string]int8), false, d)
  18048. }
  18049. func (f fastpathT) DecMapStringInt8X(vp *map[string]int8, d *Decoder) {
  18050. if v, changed := f.DecMapStringInt8V(*vp, true, d); changed {
  18051. *vp = v
  18052. }
  18053. }
  18054. func (_ fastpathT) DecMapStringInt8V(v map[string]int8, canChange bool,
  18055. d *Decoder) (_ map[string]int8, changed bool) {
  18056. dd, esep := d.d, d.hh.hasElemSeparators()
  18057. containerLen := dd.ReadMapStart()
  18058. if canChange && v == nil {
  18059. xlen := decInferLen(containerLen, d.h.MaxInitLen, 17)
  18060. v = make(map[string]int8, xlen)
  18061. changed = true
  18062. }
  18063. if containerLen == 0 {
  18064. dd.ReadMapEnd()
  18065. return v, changed
  18066. }
  18067. var mk string
  18068. var mv int8
  18069. hasLen := containerLen > 0
  18070. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18071. if esep {
  18072. dd.ReadMapElemKey()
  18073. }
  18074. mk = dd.DecodeString()
  18075. if esep {
  18076. dd.ReadMapElemValue()
  18077. }
  18078. if dd.TryDecodeAsNil() {
  18079. if d.h.DeleteOnNilMapValue {
  18080. delete(v, mk)
  18081. } else {
  18082. v[mk] = 0
  18083. }
  18084. continue
  18085. }
  18086. mv = int8(dd.DecodeInt(8))
  18087. if v != nil {
  18088. v[mk] = mv
  18089. }
  18090. }
  18091. dd.ReadMapEnd()
  18092. return v, changed
  18093. }
  18094. func (d *Decoder) fastpathDecMapStringInt16R(f *codecFnInfo, rv reflect.Value) {
  18095. if rv.Kind() == reflect.Ptr {
  18096. vp := rv2i(rv).(*map[string]int16)
  18097. if v, changed := fastpathTV.DecMapStringInt16V(*vp, true, d); changed {
  18098. *vp = v
  18099. }
  18100. return
  18101. }
  18102. fastpathTV.DecMapStringInt16V(rv2i(rv).(map[string]int16), false, d)
  18103. }
  18104. func (f fastpathT) DecMapStringInt16X(vp *map[string]int16, d *Decoder) {
  18105. if v, changed := f.DecMapStringInt16V(*vp, true, d); changed {
  18106. *vp = v
  18107. }
  18108. }
  18109. func (_ fastpathT) DecMapStringInt16V(v map[string]int16, canChange bool,
  18110. d *Decoder) (_ map[string]int16, changed bool) {
  18111. dd, esep := d.d, d.hh.hasElemSeparators()
  18112. containerLen := dd.ReadMapStart()
  18113. if canChange && v == nil {
  18114. xlen := decInferLen(containerLen, d.h.MaxInitLen, 18)
  18115. v = make(map[string]int16, xlen)
  18116. changed = true
  18117. }
  18118. if containerLen == 0 {
  18119. dd.ReadMapEnd()
  18120. return v, changed
  18121. }
  18122. var mk string
  18123. var mv int16
  18124. hasLen := containerLen > 0
  18125. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18126. if esep {
  18127. dd.ReadMapElemKey()
  18128. }
  18129. mk = dd.DecodeString()
  18130. if esep {
  18131. dd.ReadMapElemValue()
  18132. }
  18133. if dd.TryDecodeAsNil() {
  18134. if d.h.DeleteOnNilMapValue {
  18135. delete(v, mk)
  18136. } else {
  18137. v[mk] = 0
  18138. }
  18139. continue
  18140. }
  18141. mv = int16(dd.DecodeInt(16))
  18142. if v != nil {
  18143. v[mk] = mv
  18144. }
  18145. }
  18146. dd.ReadMapEnd()
  18147. return v, changed
  18148. }
  18149. func (d *Decoder) fastpathDecMapStringInt32R(f *codecFnInfo, rv reflect.Value) {
  18150. if rv.Kind() == reflect.Ptr {
  18151. vp := rv2i(rv).(*map[string]int32)
  18152. if v, changed := fastpathTV.DecMapStringInt32V(*vp, true, d); changed {
  18153. *vp = v
  18154. }
  18155. return
  18156. }
  18157. fastpathTV.DecMapStringInt32V(rv2i(rv).(map[string]int32), false, d)
  18158. }
  18159. func (f fastpathT) DecMapStringInt32X(vp *map[string]int32, d *Decoder) {
  18160. if v, changed := f.DecMapStringInt32V(*vp, true, d); changed {
  18161. *vp = v
  18162. }
  18163. }
  18164. func (_ fastpathT) DecMapStringInt32V(v map[string]int32, canChange bool,
  18165. d *Decoder) (_ map[string]int32, changed bool) {
  18166. dd, esep := d.d, d.hh.hasElemSeparators()
  18167. containerLen := dd.ReadMapStart()
  18168. if canChange && v == nil {
  18169. xlen := decInferLen(containerLen, d.h.MaxInitLen, 20)
  18170. v = make(map[string]int32, xlen)
  18171. changed = true
  18172. }
  18173. if containerLen == 0 {
  18174. dd.ReadMapEnd()
  18175. return v, changed
  18176. }
  18177. var mk string
  18178. var mv int32
  18179. hasLen := containerLen > 0
  18180. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18181. if esep {
  18182. dd.ReadMapElemKey()
  18183. }
  18184. mk = dd.DecodeString()
  18185. if esep {
  18186. dd.ReadMapElemValue()
  18187. }
  18188. if dd.TryDecodeAsNil() {
  18189. if d.h.DeleteOnNilMapValue {
  18190. delete(v, mk)
  18191. } else {
  18192. v[mk] = 0
  18193. }
  18194. continue
  18195. }
  18196. mv = int32(dd.DecodeInt(32))
  18197. if v != nil {
  18198. v[mk] = mv
  18199. }
  18200. }
  18201. dd.ReadMapEnd()
  18202. return v, changed
  18203. }
  18204. func (d *Decoder) fastpathDecMapStringInt64R(f *codecFnInfo, rv reflect.Value) {
  18205. if rv.Kind() == reflect.Ptr {
  18206. vp := rv2i(rv).(*map[string]int64)
  18207. if v, changed := fastpathTV.DecMapStringInt64V(*vp, true, d); changed {
  18208. *vp = v
  18209. }
  18210. return
  18211. }
  18212. fastpathTV.DecMapStringInt64V(rv2i(rv).(map[string]int64), false, d)
  18213. }
  18214. func (f fastpathT) DecMapStringInt64X(vp *map[string]int64, d *Decoder) {
  18215. if v, changed := f.DecMapStringInt64V(*vp, true, d); changed {
  18216. *vp = v
  18217. }
  18218. }
  18219. func (_ fastpathT) DecMapStringInt64V(v map[string]int64, canChange bool,
  18220. d *Decoder) (_ map[string]int64, changed bool) {
  18221. dd, esep := d.d, d.hh.hasElemSeparators()
  18222. containerLen := dd.ReadMapStart()
  18223. if canChange && v == nil {
  18224. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  18225. v = make(map[string]int64, xlen)
  18226. changed = true
  18227. }
  18228. if containerLen == 0 {
  18229. dd.ReadMapEnd()
  18230. return v, changed
  18231. }
  18232. var mk string
  18233. var mv int64
  18234. hasLen := containerLen > 0
  18235. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18236. if esep {
  18237. dd.ReadMapElemKey()
  18238. }
  18239. mk = dd.DecodeString()
  18240. if esep {
  18241. dd.ReadMapElemValue()
  18242. }
  18243. if dd.TryDecodeAsNil() {
  18244. if d.h.DeleteOnNilMapValue {
  18245. delete(v, mk)
  18246. } else {
  18247. v[mk] = 0
  18248. }
  18249. continue
  18250. }
  18251. mv = dd.DecodeInt(64)
  18252. if v != nil {
  18253. v[mk] = mv
  18254. }
  18255. }
  18256. dd.ReadMapEnd()
  18257. return v, changed
  18258. }
  18259. func (d *Decoder) fastpathDecMapStringFloat32R(f *codecFnInfo, rv reflect.Value) {
  18260. if rv.Kind() == reflect.Ptr {
  18261. vp := rv2i(rv).(*map[string]float32)
  18262. if v, changed := fastpathTV.DecMapStringFloat32V(*vp, true, d); changed {
  18263. *vp = v
  18264. }
  18265. return
  18266. }
  18267. fastpathTV.DecMapStringFloat32V(rv2i(rv).(map[string]float32), false, d)
  18268. }
  18269. func (f fastpathT) DecMapStringFloat32X(vp *map[string]float32, d *Decoder) {
  18270. if v, changed := f.DecMapStringFloat32V(*vp, true, d); changed {
  18271. *vp = v
  18272. }
  18273. }
  18274. func (_ fastpathT) DecMapStringFloat32V(v map[string]float32, canChange bool,
  18275. d *Decoder) (_ map[string]float32, changed bool) {
  18276. dd, esep := d.d, d.hh.hasElemSeparators()
  18277. containerLen := dd.ReadMapStart()
  18278. if canChange && v == nil {
  18279. xlen := decInferLen(containerLen, d.h.MaxInitLen, 20)
  18280. v = make(map[string]float32, xlen)
  18281. changed = true
  18282. }
  18283. if containerLen == 0 {
  18284. dd.ReadMapEnd()
  18285. return v, changed
  18286. }
  18287. var mk string
  18288. var mv float32
  18289. hasLen := containerLen > 0
  18290. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18291. if esep {
  18292. dd.ReadMapElemKey()
  18293. }
  18294. mk = dd.DecodeString()
  18295. if esep {
  18296. dd.ReadMapElemValue()
  18297. }
  18298. if dd.TryDecodeAsNil() {
  18299. if d.h.DeleteOnNilMapValue {
  18300. delete(v, mk)
  18301. } else {
  18302. v[mk] = 0
  18303. }
  18304. continue
  18305. }
  18306. mv = float32(dd.DecodeFloat(true))
  18307. if v != nil {
  18308. v[mk] = mv
  18309. }
  18310. }
  18311. dd.ReadMapEnd()
  18312. return v, changed
  18313. }
  18314. func (d *Decoder) fastpathDecMapStringFloat64R(f *codecFnInfo, rv reflect.Value) {
  18315. if rv.Kind() == reflect.Ptr {
  18316. vp := rv2i(rv).(*map[string]float64)
  18317. if v, changed := fastpathTV.DecMapStringFloat64V(*vp, true, d); changed {
  18318. *vp = v
  18319. }
  18320. return
  18321. }
  18322. fastpathTV.DecMapStringFloat64V(rv2i(rv).(map[string]float64), false, d)
  18323. }
  18324. func (f fastpathT) DecMapStringFloat64X(vp *map[string]float64, d *Decoder) {
  18325. if v, changed := f.DecMapStringFloat64V(*vp, true, d); changed {
  18326. *vp = v
  18327. }
  18328. }
  18329. func (_ fastpathT) DecMapStringFloat64V(v map[string]float64, canChange bool,
  18330. d *Decoder) (_ map[string]float64, changed bool) {
  18331. dd, esep := d.d, d.hh.hasElemSeparators()
  18332. containerLen := dd.ReadMapStart()
  18333. if canChange && v == nil {
  18334. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  18335. v = make(map[string]float64, xlen)
  18336. changed = true
  18337. }
  18338. if containerLen == 0 {
  18339. dd.ReadMapEnd()
  18340. return v, changed
  18341. }
  18342. var mk string
  18343. var mv float64
  18344. hasLen := containerLen > 0
  18345. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18346. if esep {
  18347. dd.ReadMapElemKey()
  18348. }
  18349. mk = dd.DecodeString()
  18350. if esep {
  18351. dd.ReadMapElemValue()
  18352. }
  18353. if dd.TryDecodeAsNil() {
  18354. if d.h.DeleteOnNilMapValue {
  18355. delete(v, mk)
  18356. } else {
  18357. v[mk] = 0
  18358. }
  18359. continue
  18360. }
  18361. mv = dd.DecodeFloat(false)
  18362. if v != nil {
  18363. v[mk] = mv
  18364. }
  18365. }
  18366. dd.ReadMapEnd()
  18367. return v, changed
  18368. }
  18369. func (d *Decoder) fastpathDecMapStringBoolR(f *codecFnInfo, rv reflect.Value) {
  18370. if rv.Kind() == reflect.Ptr {
  18371. vp := rv2i(rv).(*map[string]bool)
  18372. if v, changed := fastpathTV.DecMapStringBoolV(*vp, true, d); changed {
  18373. *vp = v
  18374. }
  18375. return
  18376. }
  18377. fastpathTV.DecMapStringBoolV(rv2i(rv).(map[string]bool), false, d)
  18378. }
  18379. func (f fastpathT) DecMapStringBoolX(vp *map[string]bool, d *Decoder) {
  18380. if v, changed := f.DecMapStringBoolV(*vp, true, d); changed {
  18381. *vp = v
  18382. }
  18383. }
  18384. func (_ fastpathT) DecMapStringBoolV(v map[string]bool, canChange bool,
  18385. d *Decoder) (_ map[string]bool, changed bool) {
  18386. dd, esep := d.d, d.hh.hasElemSeparators()
  18387. containerLen := dd.ReadMapStart()
  18388. if canChange && v == nil {
  18389. xlen := decInferLen(containerLen, d.h.MaxInitLen, 17)
  18390. v = make(map[string]bool, xlen)
  18391. changed = true
  18392. }
  18393. if containerLen == 0 {
  18394. dd.ReadMapEnd()
  18395. return v, changed
  18396. }
  18397. var mk string
  18398. var mv bool
  18399. hasLen := containerLen > 0
  18400. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18401. if esep {
  18402. dd.ReadMapElemKey()
  18403. }
  18404. mk = dd.DecodeString()
  18405. if esep {
  18406. dd.ReadMapElemValue()
  18407. }
  18408. if dd.TryDecodeAsNil() {
  18409. if d.h.DeleteOnNilMapValue {
  18410. delete(v, mk)
  18411. } else {
  18412. v[mk] = false
  18413. }
  18414. continue
  18415. }
  18416. mv = dd.DecodeBool()
  18417. if v != nil {
  18418. v[mk] = mv
  18419. }
  18420. }
  18421. dd.ReadMapEnd()
  18422. return v, changed
  18423. }
  18424. func (d *Decoder) fastpathDecMapFloat32IntfR(f *codecFnInfo, rv reflect.Value) {
  18425. if rv.Kind() == reflect.Ptr {
  18426. vp := rv2i(rv).(*map[float32]interface{})
  18427. if v, changed := fastpathTV.DecMapFloat32IntfV(*vp, true, d); changed {
  18428. *vp = v
  18429. }
  18430. return
  18431. }
  18432. fastpathTV.DecMapFloat32IntfV(rv2i(rv).(map[float32]interface{}), false, d)
  18433. }
  18434. func (f fastpathT) DecMapFloat32IntfX(vp *map[float32]interface{}, d *Decoder) {
  18435. if v, changed := f.DecMapFloat32IntfV(*vp, true, d); changed {
  18436. *vp = v
  18437. }
  18438. }
  18439. func (_ fastpathT) DecMapFloat32IntfV(v map[float32]interface{}, canChange bool,
  18440. d *Decoder) (_ map[float32]interface{}, changed bool) {
  18441. dd, esep := d.d, d.hh.hasElemSeparators()
  18442. containerLen := dd.ReadMapStart()
  18443. if canChange && v == nil {
  18444. xlen := decInferLen(containerLen, d.h.MaxInitLen, 20)
  18445. v = make(map[float32]interface{}, xlen)
  18446. changed = true
  18447. }
  18448. if containerLen == 0 {
  18449. dd.ReadMapEnd()
  18450. return v, changed
  18451. }
  18452. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  18453. var mk float32
  18454. var mv interface{}
  18455. hasLen := containerLen > 0
  18456. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18457. if esep {
  18458. dd.ReadMapElemKey()
  18459. }
  18460. mk = float32(dd.DecodeFloat(true))
  18461. if esep {
  18462. dd.ReadMapElemValue()
  18463. }
  18464. if dd.TryDecodeAsNil() {
  18465. if d.h.DeleteOnNilMapValue {
  18466. delete(v, mk)
  18467. } else {
  18468. v[mk] = nil
  18469. }
  18470. continue
  18471. }
  18472. if mapGet {
  18473. mv = v[mk]
  18474. } else {
  18475. mv = nil
  18476. }
  18477. d.decode(&mv)
  18478. if v != nil {
  18479. v[mk] = mv
  18480. }
  18481. }
  18482. dd.ReadMapEnd()
  18483. return v, changed
  18484. }
  18485. func (d *Decoder) fastpathDecMapFloat32StringR(f *codecFnInfo, rv reflect.Value) {
  18486. if rv.Kind() == reflect.Ptr {
  18487. vp := rv2i(rv).(*map[float32]string)
  18488. if v, changed := fastpathTV.DecMapFloat32StringV(*vp, true, d); changed {
  18489. *vp = v
  18490. }
  18491. return
  18492. }
  18493. fastpathTV.DecMapFloat32StringV(rv2i(rv).(map[float32]string), false, d)
  18494. }
  18495. func (f fastpathT) DecMapFloat32StringX(vp *map[float32]string, d *Decoder) {
  18496. if v, changed := f.DecMapFloat32StringV(*vp, true, d); changed {
  18497. *vp = v
  18498. }
  18499. }
  18500. func (_ fastpathT) DecMapFloat32StringV(v map[float32]string, canChange bool,
  18501. d *Decoder) (_ map[float32]string, changed bool) {
  18502. dd, esep := d.d, d.hh.hasElemSeparators()
  18503. containerLen := dd.ReadMapStart()
  18504. if canChange && v == nil {
  18505. xlen := decInferLen(containerLen, d.h.MaxInitLen, 20)
  18506. v = make(map[float32]string, xlen)
  18507. changed = true
  18508. }
  18509. if containerLen == 0 {
  18510. dd.ReadMapEnd()
  18511. return v, changed
  18512. }
  18513. var mk float32
  18514. var mv string
  18515. hasLen := containerLen > 0
  18516. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18517. if esep {
  18518. dd.ReadMapElemKey()
  18519. }
  18520. mk = float32(dd.DecodeFloat(true))
  18521. if esep {
  18522. dd.ReadMapElemValue()
  18523. }
  18524. if dd.TryDecodeAsNil() {
  18525. if d.h.DeleteOnNilMapValue {
  18526. delete(v, mk)
  18527. } else {
  18528. v[mk] = ""
  18529. }
  18530. continue
  18531. }
  18532. mv = dd.DecodeString()
  18533. if v != nil {
  18534. v[mk] = mv
  18535. }
  18536. }
  18537. dd.ReadMapEnd()
  18538. return v, changed
  18539. }
  18540. func (d *Decoder) fastpathDecMapFloat32UintR(f *codecFnInfo, rv reflect.Value) {
  18541. if rv.Kind() == reflect.Ptr {
  18542. vp := rv2i(rv).(*map[float32]uint)
  18543. if v, changed := fastpathTV.DecMapFloat32UintV(*vp, true, d); changed {
  18544. *vp = v
  18545. }
  18546. return
  18547. }
  18548. fastpathTV.DecMapFloat32UintV(rv2i(rv).(map[float32]uint), false, d)
  18549. }
  18550. func (f fastpathT) DecMapFloat32UintX(vp *map[float32]uint, d *Decoder) {
  18551. if v, changed := f.DecMapFloat32UintV(*vp, true, d); changed {
  18552. *vp = v
  18553. }
  18554. }
  18555. func (_ fastpathT) DecMapFloat32UintV(v map[float32]uint, canChange bool,
  18556. d *Decoder) (_ map[float32]uint, changed bool) {
  18557. dd, esep := d.d, d.hh.hasElemSeparators()
  18558. containerLen := dd.ReadMapStart()
  18559. if canChange && v == nil {
  18560. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  18561. v = make(map[float32]uint, xlen)
  18562. changed = true
  18563. }
  18564. if containerLen == 0 {
  18565. dd.ReadMapEnd()
  18566. return v, changed
  18567. }
  18568. var mk float32
  18569. var mv uint
  18570. hasLen := containerLen > 0
  18571. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18572. if esep {
  18573. dd.ReadMapElemKey()
  18574. }
  18575. mk = float32(dd.DecodeFloat(true))
  18576. if esep {
  18577. dd.ReadMapElemValue()
  18578. }
  18579. if dd.TryDecodeAsNil() {
  18580. if d.h.DeleteOnNilMapValue {
  18581. delete(v, mk)
  18582. } else {
  18583. v[mk] = 0
  18584. }
  18585. continue
  18586. }
  18587. mv = uint(dd.DecodeUint(uintBitsize))
  18588. if v != nil {
  18589. v[mk] = mv
  18590. }
  18591. }
  18592. dd.ReadMapEnd()
  18593. return v, changed
  18594. }
  18595. func (d *Decoder) fastpathDecMapFloat32Uint8R(f *codecFnInfo, rv reflect.Value) {
  18596. if rv.Kind() == reflect.Ptr {
  18597. vp := rv2i(rv).(*map[float32]uint8)
  18598. if v, changed := fastpathTV.DecMapFloat32Uint8V(*vp, true, d); changed {
  18599. *vp = v
  18600. }
  18601. return
  18602. }
  18603. fastpathTV.DecMapFloat32Uint8V(rv2i(rv).(map[float32]uint8), false, d)
  18604. }
  18605. func (f fastpathT) DecMapFloat32Uint8X(vp *map[float32]uint8, d *Decoder) {
  18606. if v, changed := f.DecMapFloat32Uint8V(*vp, true, d); changed {
  18607. *vp = v
  18608. }
  18609. }
  18610. func (_ fastpathT) DecMapFloat32Uint8V(v map[float32]uint8, canChange bool,
  18611. d *Decoder) (_ map[float32]uint8, changed bool) {
  18612. dd, esep := d.d, d.hh.hasElemSeparators()
  18613. containerLen := dd.ReadMapStart()
  18614. if canChange && v == nil {
  18615. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  18616. v = make(map[float32]uint8, xlen)
  18617. changed = true
  18618. }
  18619. if containerLen == 0 {
  18620. dd.ReadMapEnd()
  18621. return v, changed
  18622. }
  18623. var mk float32
  18624. var mv uint8
  18625. hasLen := containerLen > 0
  18626. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18627. if esep {
  18628. dd.ReadMapElemKey()
  18629. }
  18630. mk = float32(dd.DecodeFloat(true))
  18631. if esep {
  18632. dd.ReadMapElemValue()
  18633. }
  18634. if dd.TryDecodeAsNil() {
  18635. if d.h.DeleteOnNilMapValue {
  18636. delete(v, mk)
  18637. } else {
  18638. v[mk] = 0
  18639. }
  18640. continue
  18641. }
  18642. mv = uint8(dd.DecodeUint(8))
  18643. if v != nil {
  18644. v[mk] = mv
  18645. }
  18646. }
  18647. dd.ReadMapEnd()
  18648. return v, changed
  18649. }
  18650. func (d *Decoder) fastpathDecMapFloat32Uint16R(f *codecFnInfo, rv reflect.Value) {
  18651. if rv.Kind() == reflect.Ptr {
  18652. vp := rv2i(rv).(*map[float32]uint16)
  18653. if v, changed := fastpathTV.DecMapFloat32Uint16V(*vp, true, d); changed {
  18654. *vp = v
  18655. }
  18656. return
  18657. }
  18658. fastpathTV.DecMapFloat32Uint16V(rv2i(rv).(map[float32]uint16), false, d)
  18659. }
  18660. func (f fastpathT) DecMapFloat32Uint16X(vp *map[float32]uint16, d *Decoder) {
  18661. if v, changed := f.DecMapFloat32Uint16V(*vp, true, d); changed {
  18662. *vp = v
  18663. }
  18664. }
  18665. func (_ fastpathT) DecMapFloat32Uint16V(v map[float32]uint16, canChange bool,
  18666. d *Decoder) (_ map[float32]uint16, changed bool) {
  18667. dd, esep := d.d, d.hh.hasElemSeparators()
  18668. containerLen := dd.ReadMapStart()
  18669. if canChange && v == nil {
  18670. xlen := decInferLen(containerLen, d.h.MaxInitLen, 6)
  18671. v = make(map[float32]uint16, xlen)
  18672. changed = true
  18673. }
  18674. if containerLen == 0 {
  18675. dd.ReadMapEnd()
  18676. return v, changed
  18677. }
  18678. var mk float32
  18679. var mv uint16
  18680. hasLen := containerLen > 0
  18681. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18682. if esep {
  18683. dd.ReadMapElemKey()
  18684. }
  18685. mk = float32(dd.DecodeFloat(true))
  18686. if esep {
  18687. dd.ReadMapElemValue()
  18688. }
  18689. if dd.TryDecodeAsNil() {
  18690. if d.h.DeleteOnNilMapValue {
  18691. delete(v, mk)
  18692. } else {
  18693. v[mk] = 0
  18694. }
  18695. continue
  18696. }
  18697. mv = uint16(dd.DecodeUint(16))
  18698. if v != nil {
  18699. v[mk] = mv
  18700. }
  18701. }
  18702. dd.ReadMapEnd()
  18703. return v, changed
  18704. }
  18705. func (d *Decoder) fastpathDecMapFloat32Uint32R(f *codecFnInfo, rv reflect.Value) {
  18706. if rv.Kind() == reflect.Ptr {
  18707. vp := rv2i(rv).(*map[float32]uint32)
  18708. if v, changed := fastpathTV.DecMapFloat32Uint32V(*vp, true, d); changed {
  18709. *vp = v
  18710. }
  18711. return
  18712. }
  18713. fastpathTV.DecMapFloat32Uint32V(rv2i(rv).(map[float32]uint32), false, d)
  18714. }
  18715. func (f fastpathT) DecMapFloat32Uint32X(vp *map[float32]uint32, d *Decoder) {
  18716. if v, changed := f.DecMapFloat32Uint32V(*vp, true, d); changed {
  18717. *vp = v
  18718. }
  18719. }
  18720. func (_ fastpathT) DecMapFloat32Uint32V(v map[float32]uint32, canChange bool,
  18721. d *Decoder) (_ map[float32]uint32, changed bool) {
  18722. dd, esep := d.d, d.hh.hasElemSeparators()
  18723. containerLen := dd.ReadMapStart()
  18724. if canChange && v == nil {
  18725. xlen := decInferLen(containerLen, d.h.MaxInitLen, 8)
  18726. v = make(map[float32]uint32, xlen)
  18727. changed = true
  18728. }
  18729. if containerLen == 0 {
  18730. dd.ReadMapEnd()
  18731. return v, changed
  18732. }
  18733. var mk float32
  18734. var mv uint32
  18735. hasLen := containerLen > 0
  18736. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18737. if esep {
  18738. dd.ReadMapElemKey()
  18739. }
  18740. mk = float32(dd.DecodeFloat(true))
  18741. if esep {
  18742. dd.ReadMapElemValue()
  18743. }
  18744. if dd.TryDecodeAsNil() {
  18745. if d.h.DeleteOnNilMapValue {
  18746. delete(v, mk)
  18747. } else {
  18748. v[mk] = 0
  18749. }
  18750. continue
  18751. }
  18752. mv = uint32(dd.DecodeUint(32))
  18753. if v != nil {
  18754. v[mk] = mv
  18755. }
  18756. }
  18757. dd.ReadMapEnd()
  18758. return v, changed
  18759. }
  18760. func (d *Decoder) fastpathDecMapFloat32Uint64R(f *codecFnInfo, rv reflect.Value) {
  18761. if rv.Kind() == reflect.Ptr {
  18762. vp := rv2i(rv).(*map[float32]uint64)
  18763. if v, changed := fastpathTV.DecMapFloat32Uint64V(*vp, true, d); changed {
  18764. *vp = v
  18765. }
  18766. return
  18767. }
  18768. fastpathTV.DecMapFloat32Uint64V(rv2i(rv).(map[float32]uint64), false, d)
  18769. }
  18770. func (f fastpathT) DecMapFloat32Uint64X(vp *map[float32]uint64, d *Decoder) {
  18771. if v, changed := f.DecMapFloat32Uint64V(*vp, true, d); changed {
  18772. *vp = v
  18773. }
  18774. }
  18775. func (_ fastpathT) DecMapFloat32Uint64V(v map[float32]uint64, canChange bool,
  18776. d *Decoder) (_ map[float32]uint64, changed bool) {
  18777. dd, esep := d.d, d.hh.hasElemSeparators()
  18778. containerLen := dd.ReadMapStart()
  18779. if canChange && v == nil {
  18780. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  18781. v = make(map[float32]uint64, xlen)
  18782. changed = true
  18783. }
  18784. if containerLen == 0 {
  18785. dd.ReadMapEnd()
  18786. return v, changed
  18787. }
  18788. var mk float32
  18789. var mv uint64
  18790. hasLen := containerLen > 0
  18791. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18792. if esep {
  18793. dd.ReadMapElemKey()
  18794. }
  18795. mk = float32(dd.DecodeFloat(true))
  18796. if esep {
  18797. dd.ReadMapElemValue()
  18798. }
  18799. if dd.TryDecodeAsNil() {
  18800. if d.h.DeleteOnNilMapValue {
  18801. delete(v, mk)
  18802. } else {
  18803. v[mk] = 0
  18804. }
  18805. continue
  18806. }
  18807. mv = dd.DecodeUint(64)
  18808. if v != nil {
  18809. v[mk] = mv
  18810. }
  18811. }
  18812. dd.ReadMapEnd()
  18813. return v, changed
  18814. }
  18815. func (d *Decoder) fastpathDecMapFloat32UintptrR(f *codecFnInfo, rv reflect.Value) {
  18816. if rv.Kind() == reflect.Ptr {
  18817. vp := rv2i(rv).(*map[float32]uintptr)
  18818. if v, changed := fastpathTV.DecMapFloat32UintptrV(*vp, true, d); changed {
  18819. *vp = v
  18820. }
  18821. return
  18822. }
  18823. fastpathTV.DecMapFloat32UintptrV(rv2i(rv).(map[float32]uintptr), false, d)
  18824. }
  18825. func (f fastpathT) DecMapFloat32UintptrX(vp *map[float32]uintptr, d *Decoder) {
  18826. if v, changed := f.DecMapFloat32UintptrV(*vp, true, d); changed {
  18827. *vp = v
  18828. }
  18829. }
  18830. func (_ fastpathT) DecMapFloat32UintptrV(v map[float32]uintptr, canChange bool,
  18831. d *Decoder) (_ map[float32]uintptr, changed bool) {
  18832. dd, esep := d.d, d.hh.hasElemSeparators()
  18833. containerLen := dd.ReadMapStart()
  18834. if canChange && v == nil {
  18835. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  18836. v = make(map[float32]uintptr, xlen)
  18837. changed = true
  18838. }
  18839. if containerLen == 0 {
  18840. dd.ReadMapEnd()
  18841. return v, changed
  18842. }
  18843. var mk float32
  18844. var mv uintptr
  18845. hasLen := containerLen > 0
  18846. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18847. if esep {
  18848. dd.ReadMapElemKey()
  18849. }
  18850. mk = float32(dd.DecodeFloat(true))
  18851. if esep {
  18852. dd.ReadMapElemValue()
  18853. }
  18854. if dd.TryDecodeAsNil() {
  18855. if d.h.DeleteOnNilMapValue {
  18856. delete(v, mk)
  18857. } else {
  18858. v[mk] = 0
  18859. }
  18860. continue
  18861. }
  18862. mv = uintptr(dd.DecodeUint(uintBitsize))
  18863. if v != nil {
  18864. v[mk] = mv
  18865. }
  18866. }
  18867. dd.ReadMapEnd()
  18868. return v, changed
  18869. }
  18870. func (d *Decoder) fastpathDecMapFloat32IntR(f *codecFnInfo, rv reflect.Value) {
  18871. if rv.Kind() == reflect.Ptr {
  18872. vp := rv2i(rv).(*map[float32]int)
  18873. if v, changed := fastpathTV.DecMapFloat32IntV(*vp, true, d); changed {
  18874. *vp = v
  18875. }
  18876. return
  18877. }
  18878. fastpathTV.DecMapFloat32IntV(rv2i(rv).(map[float32]int), false, d)
  18879. }
  18880. func (f fastpathT) DecMapFloat32IntX(vp *map[float32]int, d *Decoder) {
  18881. if v, changed := f.DecMapFloat32IntV(*vp, true, d); changed {
  18882. *vp = v
  18883. }
  18884. }
  18885. func (_ fastpathT) DecMapFloat32IntV(v map[float32]int, canChange bool,
  18886. d *Decoder) (_ map[float32]int, changed bool) {
  18887. dd, esep := d.d, d.hh.hasElemSeparators()
  18888. containerLen := dd.ReadMapStart()
  18889. if canChange && v == nil {
  18890. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  18891. v = make(map[float32]int, xlen)
  18892. changed = true
  18893. }
  18894. if containerLen == 0 {
  18895. dd.ReadMapEnd()
  18896. return v, changed
  18897. }
  18898. var mk float32
  18899. var mv int
  18900. hasLen := containerLen > 0
  18901. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18902. if esep {
  18903. dd.ReadMapElemKey()
  18904. }
  18905. mk = float32(dd.DecodeFloat(true))
  18906. if esep {
  18907. dd.ReadMapElemValue()
  18908. }
  18909. if dd.TryDecodeAsNil() {
  18910. if d.h.DeleteOnNilMapValue {
  18911. delete(v, mk)
  18912. } else {
  18913. v[mk] = 0
  18914. }
  18915. continue
  18916. }
  18917. mv = int(dd.DecodeInt(intBitsize))
  18918. if v != nil {
  18919. v[mk] = mv
  18920. }
  18921. }
  18922. dd.ReadMapEnd()
  18923. return v, changed
  18924. }
  18925. func (d *Decoder) fastpathDecMapFloat32Int8R(f *codecFnInfo, rv reflect.Value) {
  18926. if rv.Kind() == reflect.Ptr {
  18927. vp := rv2i(rv).(*map[float32]int8)
  18928. if v, changed := fastpathTV.DecMapFloat32Int8V(*vp, true, d); changed {
  18929. *vp = v
  18930. }
  18931. return
  18932. }
  18933. fastpathTV.DecMapFloat32Int8V(rv2i(rv).(map[float32]int8), false, d)
  18934. }
  18935. func (f fastpathT) DecMapFloat32Int8X(vp *map[float32]int8, d *Decoder) {
  18936. if v, changed := f.DecMapFloat32Int8V(*vp, true, d); changed {
  18937. *vp = v
  18938. }
  18939. }
  18940. func (_ fastpathT) DecMapFloat32Int8V(v map[float32]int8, canChange bool,
  18941. d *Decoder) (_ map[float32]int8, changed bool) {
  18942. dd, esep := d.d, d.hh.hasElemSeparators()
  18943. containerLen := dd.ReadMapStart()
  18944. if canChange && v == nil {
  18945. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  18946. v = make(map[float32]int8, xlen)
  18947. changed = true
  18948. }
  18949. if containerLen == 0 {
  18950. dd.ReadMapEnd()
  18951. return v, changed
  18952. }
  18953. var mk float32
  18954. var mv int8
  18955. hasLen := containerLen > 0
  18956. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18957. if esep {
  18958. dd.ReadMapElemKey()
  18959. }
  18960. mk = float32(dd.DecodeFloat(true))
  18961. if esep {
  18962. dd.ReadMapElemValue()
  18963. }
  18964. if dd.TryDecodeAsNil() {
  18965. if d.h.DeleteOnNilMapValue {
  18966. delete(v, mk)
  18967. } else {
  18968. v[mk] = 0
  18969. }
  18970. continue
  18971. }
  18972. mv = int8(dd.DecodeInt(8))
  18973. if v != nil {
  18974. v[mk] = mv
  18975. }
  18976. }
  18977. dd.ReadMapEnd()
  18978. return v, changed
  18979. }
  18980. func (d *Decoder) fastpathDecMapFloat32Int16R(f *codecFnInfo, rv reflect.Value) {
  18981. if rv.Kind() == reflect.Ptr {
  18982. vp := rv2i(rv).(*map[float32]int16)
  18983. if v, changed := fastpathTV.DecMapFloat32Int16V(*vp, true, d); changed {
  18984. *vp = v
  18985. }
  18986. return
  18987. }
  18988. fastpathTV.DecMapFloat32Int16V(rv2i(rv).(map[float32]int16), false, d)
  18989. }
  18990. func (f fastpathT) DecMapFloat32Int16X(vp *map[float32]int16, d *Decoder) {
  18991. if v, changed := f.DecMapFloat32Int16V(*vp, true, d); changed {
  18992. *vp = v
  18993. }
  18994. }
  18995. func (_ fastpathT) DecMapFloat32Int16V(v map[float32]int16, canChange bool,
  18996. d *Decoder) (_ map[float32]int16, changed bool) {
  18997. dd, esep := d.d, d.hh.hasElemSeparators()
  18998. containerLen := dd.ReadMapStart()
  18999. if canChange && v == nil {
  19000. xlen := decInferLen(containerLen, d.h.MaxInitLen, 6)
  19001. v = make(map[float32]int16, xlen)
  19002. changed = true
  19003. }
  19004. if containerLen == 0 {
  19005. dd.ReadMapEnd()
  19006. return v, changed
  19007. }
  19008. var mk float32
  19009. var mv int16
  19010. hasLen := containerLen > 0
  19011. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19012. if esep {
  19013. dd.ReadMapElemKey()
  19014. }
  19015. mk = float32(dd.DecodeFloat(true))
  19016. if esep {
  19017. dd.ReadMapElemValue()
  19018. }
  19019. if dd.TryDecodeAsNil() {
  19020. if d.h.DeleteOnNilMapValue {
  19021. delete(v, mk)
  19022. } else {
  19023. v[mk] = 0
  19024. }
  19025. continue
  19026. }
  19027. mv = int16(dd.DecodeInt(16))
  19028. if v != nil {
  19029. v[mk] = mv
  19030. }
  19031. }
  19032. dd.ReadMapEnd()
  19033. return v, changed
  19034. }
  19035. func (d *Decoder) fastpathDecMapFloat32Int32R(f *codecFnInfo, rv reflect.Value) {
  19036. if rv.Kind() == reflect.Ptr {
  19037. vp := rv2i(rv).(*map[float32]int32)
  19038. if v, changed := fastpathTV.DecMapFloat32Int32V(*vp, true, d); changed {
  19039. *vp = v
  19040. }
  19041. return
  19042. }
  19043. fastpathTV.DecMapFloat32Int32V(rv2i(rv).(map[float32]int32), false, d)
  19044. }
  19045. func (f fastpathT) DecMapFloat32Int32X(vp *map[float32]int32, d *Decoder) {
  19046. if v, changed := f.DecMapFloat32Int32V(*vp, true, d); changed {
  19047. *vp = v
  19048. }
  19049. }
  19050. func (_ fastpathT) DecMapFloat32Int32V(v map[float32]int32, canChange bool,
  19051. d *Decoder) (_ map[float32]int32, changed bool) {
  19052. dd, esep := d.d, d.hh.hasElemSeparators()
  19053. containerLen := dd.ReadMapStart()
  19054. if canChange && v == nil {
  19055. xlen := decInferLen(containerLen, d.h.MaxInitLen, 8)
  19056. v = make(map[float32]int32, xlen)
  19057. changed = true
  19058. }
  19059. if containerLen == 0 {
  19060. dd.ReadMapEnd()
  19061. return v, changed
  19062. }
  19063. var mk float32
  19064. var mv int32
  19065. hasLen := containerLen > 0
  19066. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19067. if esep {
  19068. dd.ReadMapElemKey()
  19069. }
  19070. mk = float32(dd.DecodeFloat(true))
  19071. if esep {
  19072. dd.ReadMapElemValue()
  19073. }
  19074. if dd.TryDecodeAsNil() {
  19075. if d.h.DeleteOnNilMapValue {
  19076. delete(v, mk)
  19077. } else {
  19078. v[mk] = 0
  19079. }
  19080. continue
  19081. }
  19082. mv = int32(dd.DecodeInt(32))
  19083. if v != nil {
  19084. v[mk] = mv
  19085. }
  19086. }
  19087. dd.ReadMapEnd()
  19088. return v, changed
  19089. }
  19090. func (d *Decoder) fastpathDecMapFloat32Int64R(f *codecFnInfo, rv reflect.Value) {
  19091. if rv.Kind() == reflect.Ptr {
  19092. vp := rv2i(rv).(*map[float32]int64)
  19093. if v, changed := fastpathTV.DecMapFloat32Int64V(*vp, true, d); changed {
  19094. *vp = v
  19095. }
  19096. return
  19097. }
  19098. fastpathTV.DecMapFloat32Int64V(rv2i(rv).(map[float32]int64), false, d)
  19099. }
  19100. func (f fastpathT) DecMapFloat32Int64X(vp *map[float32]int64, d *Decoder) {
  19101. if v, changed := f.DecMapFloat32Int64V(*vp, true, d); changed {
  19102. *vp = v
  19103. }
  19104. }
  19105. func (_ fastpathT) DecMapFloat32Int64V(v map[float32]int64, canChange bool,
  19106. d *Decoder) (_ map[float32]int64, changed bool) {
  19107. dd, esep := d.d, d.hh.hasElemSeparators()
  19108. containerLen := dd.ReadMapStart()
  19109. if canChange && v == nil {
  19110. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  19111. v = make(map[float32]int64, xlen)
  19112. changed = true
  19113. }
  19114. if containerLen == 0 {
  19115. dd.ReadMapEnd()
  19116. return v, changed
  19117. }
  19118. var mk float32
  19119. var mv int64
  19120. hasLen := containerLen > 0
  19121. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19122. if esep {
  19123. dd.ReadMapElemKey()
  19124. }
  19125. mk = float32(dd.DecodeFloat(true))
  19126. if esep {
  19127. dd.ReadMapElemValue()
  19128. }
  19129. if dd.TryDecodeAsNil() {
  19130. if d.h.DeleteOnNilMapValue {
  19131. delete(v, mk)
  19132. } else {
  19133. v[mk] = 0
  19134. }
  19135. continue
  19136. }
  19137. mv = dd.DecodeInt(64)
  19138. if v != nil {
  19139. v[mk] = mv
  19140. }
  19141. }
  19142. dd.ReadMapEnd()
  19143. return v, changed
  19144. }
  19145. func (d *Decoder) fastpathDecMapFloat32Float32R(f *codecFnInfo, rv reflect.Value) {
  19146. if rv.Kind() == reflect.Ptr {
  19147. vp := rv2i(rv).(*map[float32]float32)
  19148. if v, changed := fastpathTV.DecMapFloat32Float32V(*vp, true, d); changed {
  19149. *vp = v
  19150. }
  19151. return
  19152. }
  19153. fastpathTV.DecMapFloat32Float32V(rv2i(rv).(map[float32]float32), false, d)
  19154. }
  19155. func (f fastpathT) DecMapFloat32Float32X(vp *map[float32]float32, d *Decoder) {
  19156. if v, changed := f.DecMapFloat32Float32V(*vp, true, d); changed {
  19157. *vp = v
  19158. }
  19159. }
  19160. func (_ fastpathT) DecMapFloat32Float32V(v map[float32]float32, canChange bool,
  19161. d *Decoder) (_ map[float32]float32, changed bool) {
  19162. dd, esep := d.d, d.hh.hasElemSeparators()
  19163. containerLen := dd.ReadMapStart()
  19164. if canChange && v == nil {
  19165. xlen := decInferLen(containerLen, d.h.MaxInitLen, 8)
  19166. v = make(map[float32]float32, xlen)
  19167. changed = true
  19168. }
  19169. if containerLen == 0 {
  19170. dd.ReadMapEnd()
  19171. return v, changed
  19172. }
  19173. var mk float32
  19174. var mv float32
  19175. hasLen := containerLen > 0
  19176. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19177. if esep {
  19178. dd.ReadMapElemKey()
  19179. }
  19180. mk = float32(dd.DecodeFloat(true))
  19181. if esep {
  19182. dd.ReadMapElemValue()
  19183. }
  19184. if dd.TryDecodeAsNil() {
  19185. if d.h.DeleteOnNilMapValue {
  19186. delete(v, mk)
  19187. } else {
  19188. v[mk] = 0
  19189. }
  19190. continue
  19191. }
  19192. mv = float32(dd.DecodeFloat(true))
  19193. if v != nil {
  19194. v[mk] = mv
  19195. }
  19196. }
  19197. dd.ReadMapEnd()
  19198. return v, changed
  19199. }
  19200. func (d *Decoder) fastpathDecMapFloat32Float64R(f *codecFnInfo, rv reflect.Value) {
  19201. if rv.Kind() == reflect.Ptr {
  19202. vp := rv2i(rv).(*map[float32]float64)
  19203. if v, changed := fastpathTV.DecMapFloat32Float64V(*vp, true, d); changed {
  19204. *vp = v
  19205. }
  19206. return
  19207. }
  19208. fastpathTV.DecMapFloat32Float64V(rv2i(rv).(map[float32]float64), false, d)
  19209. }
  19210. func (f fastpathT) DecMapFloat32Float64X(vp *map[float32]float64, d *Decoder) {
  19211. if v, changed := f.DecMapFloat32Float64V(*vp, true, d); changed {
  19212. *vp = v
  19213. }
  19214. }
  19215. func (_ fastpathT) DecMapFloat32Float64V(v map[float32]float64, canChange bool,
  19216. d *Decoder) (_ map[float32]float64, changed bool) {
  19217. dd, esep := d.d, d.hh.hasElemSeparators()
  19218. containerLen := dd.ReadMapStart()
  19219. if canChange && v == nil {
  19220. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  19221. v = make(map[float32]float64, xlen)
  19222. changed = true
  19223. }
  19224. if containerLen == 0 {
  19225. dd.ReadMapEnd()
  19226. return v, changed
  19227. }
  19228. var mk float32
  19229. var mv float64
  19230. hasLen := containerLen > 0
  19231. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19232. if esep {
  19233. dd.ReadMapElemKey()
  19234. }
  19235. mk = float32(dd.DecodeFloat(true))
  19236. if esep {
  19237. dd.ReadMapElemValue()
  19238. }
  19239. if dd.TryDecodeAsNil() {
  19240. if d.h.DeleteOnNilMapValue {
  19241. delete(v, mk)
  19242. } else {
  19243. v[mk] = 0
  19244. }
  19245. continue
  19246. }
  19247. mv = dd.DecodeFloat(false)
  19248. if v != nil {
  19249. v[mk] = mv
  19250. }
  19251. }
  19252. dd.ReadMapEnd()
  19253. return v, changed
  19254. }
  19255. func (d *Decoder) fastpathDecMapFloat32BoolR(f *codecFnInfo, rv reflect.Value) {
  19256. if rv.Kind() == reflect.Ptr {
  19257. vp := rv2i(rv).(*map[float32]bool)
  19258. if v, changed := fastpathTV.DecMapFloat32BoolV(*vp, true, d); changed {
  19259. *vp = v
  19260. }
  19261. return
  19262. }
  19263. fastpathTV.DecMapFloat32BoolV(rv2i(rv).(map[float32]bool), false, d)
  19264. }
  19265. func (f fastpathT) DecMapFloat32BoolX(vp *map[float32]bool, d *Decoder) {
  19266. if v, changed := f.DecMapFloat32BoolV(*vp, true, d); changed {
  19267. *vp = v
  19268. }
  19269. }
  19270. func (_ fastpathT) DecMapFloat32BoolV(v map[float32]bool, canChange bool,
  19271. d *Decoder) (_ map[float32]bool, changed bool) {
  19272. dd, esep := d.d, d.hh.hasElemSeparators()
  19273. containerLen := dd.ReadMapStart()
  19274. if canChange && v == nil {
  19275. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  19276. v = make(map[float32]bool, xlen)
  19277. changed = true
  19278. }
  19279. if containerLen == 0 {
  19280. dd.ReadMapEnd()
  19281. return v, changed
  19282. }
  19283. var mk float32
  19284. var mv bool
  19285. hasLen := containerLen > 0
  19286. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19287. if esep {
  19288. dd.ReadMapElemKey()
  19289. }
  19290. mk = float32(dd.DecodeFloat(true))
  19291. if esep {
  19292. dd.ReadMapElemValue()
  19293. }
  19294. if dd.TryDecodeAsNil() {
  19295. if d.h.DeleteOnNilMapValue {
  19296. delete(v, mk)
  19297. } else {
  19298. v[mk] = false
  19299. }
  19300. continue
  19301. }
  19302. mv = dd.DecodeBool()
  19303. if v != nil {
  19304. v[mk] = mv
  19305. }
  19306. }
  19307. dd.ReadMapEnd()
  19308. return v, changed
  19309. }
  19310. func (d *Decoder) fastpathDecMapFloat64IntfR(f *codecFnInfo, rv reflect.Value) {
  19311. if rv.Kind() == reflect.Ptr {
  19312. vp := rv2i(rv).(*map[float64]interface{})
  19313. if v, changed := fastpathTV.DecMapFloat64IntfV(*vp, true, d); changed {
  19314. *vp = v
  19315. }
  19316. return
  19317. }
  19318. fastpathTV.DecMapFloat64IntfV(rv2i(rv).(map[float64]interface{}), false, d)
  19319. }
  19320. func (f fastpathT) DecMapFloat64IntfX(vp *map[float64]interface{}, d *Decoder) {
  19321. if v, changed := f.DecMapFloat64IntfV(*vp, true, d); changed {
  19322. *vp = v
  19323. }
  19324. }
  19325. func (_ fastpathT) DecMapFloat64IntfV(v map[float64]interface{}, canChange bool,
  19326. d *Decoder) (_ map[float64]interface{}, changed bool) {
  19327. dd, esep := d.d, d.hh.hasElemSeparators()
  19328. containerLen := dd.ReadMapStart()
  19329. if canChange && v == nil {
  19330. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  19331. v = make(map[float64]interface{}, xlen)
  19332. changed = true
  19333. }
  19334. if containerLen == 0 {
  19335. dd.ReadMapEnd()
  19336. return v, changed
  19337. }
  19338. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  19339. var mk float64
  19340. var mv interface{}
  19341. hasLen := containerLen > 0
  19342. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19343. if esep {
  19344. dd.ReadMapElemKey()
  19345. }
  19346. mk = dd.DecodeFloat(false)
  19347. if esep {
  19348. dd.ReadMapElemValue()
  19349. }
  19350. if dd.TryDecodeAsNil() {
  19351. if d.h.DeleteOnNilMapValue {
  19352. delete(v, mk)
  19353. } else {
  19354. v[mk] = nil
  19355. }
  19356. continue
  19357. }
  19358. if mapGet {
  19359. mv = v[mk]
  19360. } else {
  19361. mv = nil
  19362. }
  19363. d.decode(&mv)
  19364. if v != nil {
  19365. v[mk] = mv
  19366. }
  19367. }
  19368. dd.ReadMapEnd()
  19369. return v, changed
  19370. }
  19371. func (d *Decoder) fastpathDecMapFloat64StringR(f *codecFnInfo, rv reflect.Value) {
  19372. if rv.Kind() == reflect.Ptr {
  19373. vp := rv2i(rv).(*map[float64]string)
  19374. if v, changed := fastpathTV.DecMapFloat64StringV(*vp, true, d); changed {
  19375. *vp = v
  19376. }
  19377. return
  19378. }
  19379. fastpathTV.DecMapFloat64StringV(rv2i(rv).(map[float64]string), false, d)
  19380. }
  19381. func (f fastpathT) DecMapFloat64StringX(vp *map[float64]string, d *Decoder) {
  19382. if v, changed := f.DecMapFloat64StringV(*vp, true, d); changed {
  19383. *vp = v
  19384. }
  19385. }
  19386. func (_ fastpathT) DecMapFloat64StringV(v map[float64]string, canChange bool,
  19387. d *Decoder) (_ map[float64]string, changed bool) {
  19388. dd, esep := d.d, d.hh.hasElemSeparators()
  19389. containerLen := dd.ReadMapStart()
  19390. if canChange && v == nil {
  19391. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  19392. v = make(map[float64]string, xlen)
  19393. changed = true
  19394. }
  19395. if containerLen == 0 {
  19396. dd.ReadMapEnd()
  19397. return v, changed
  19398. }
  19399. var mk float64
  19400. var mv string
  19401. hasLen := containerLen > 0
  19402. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19403. if esep {
  19404. dd.ReadMapElemKey()
  19405. }
  19406. mk = dd.DecodeFloat(false)
  19407. if esep {
  19408. dd.ReadMapElemValue()
  19409. }
  19410. if dd.TryDecodeAsNil() {
  19411. if d.h.DeleteOnNilMapValue {
  19412. delete(v, mk)
  19413. } else {
  19414. v[mk] = ""
  19415. }
  19416. continue
  19417. }
  19418. mv = dd.DecodeString()
  19419. if v != nil {
  19420. v[mk] = mv
  19421. }
  19422. }
  19423. dd.ReadMapEnd()
  19424. return v, changed
  19425. }
  19426. func (d *Decoder) fastpathDecMapFloat64UintR(f *codecFnInfo, rv reflect.Value) {
  19427. if rv.Kind() == reflect.Ptr {
  19428. vp := rv2i(rv).(*map[float64]uint)
  19429. if v, changed := fastpathTV.DecMapFloat64UintV(*vp, true, d); changed {
  19430. *vp = v
  19431. }
  19432. return
  19433. }
  19434. fastpathTV.DecMapFloat64UintV(rv2i(rv).(map[float64]uint), false, d)
  19435. }
  19436. func (f fastpathT) DecMapFloat64UintX(vp *map[float64]uint, d *Decoder) {
  19437. if v, changed := f.DecMapFloat64UintV(*vp, true, d); changed {
  19438. *vp = v
  19439. }
  19440. }
  19441. func (_ fastpathT) DecMapFloat64UintV(v map[float64]uint, canChange bool,
  19442. d *Decoder) (_ map[float64]uint, changed bool) {
  19443. dd, esep := d.d, d.hh.hasElemSeparators()
  19444. containerLen := dd.ReadMapStart()
  19445. if canChange && v == nil {
  19446. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  19447. v = make(map[float64]uint, xlen)
  19448. changed = true
  19449. }
  19450. if containerLen == 0 {
  19451. dd.ReadMapEnd()
  19452. return v, changed
  19453. }
  19454. var mk float64
  19455. var mv uint
  19456. hasLen := containerLen > 0
  19457. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19458. if esep {
  19459. dd.ReadMapElemKey()
  19460. }
  19461. mk = dd.DecodeFloat(false)
  19462. if esep {
  19463. dd.ReadMapElemValue()
  19464. }
  19465. if dd.TryDecodeAsNil() {
  19466. if d.h.DeleteOnNilMapValue {
  19467. delete(v, mk)
  19468. } else {
  19469. v[mk] = 0
  19470. }
  19471. continue
  19472. }
  19473. mv = uint(dd.DecodeUint(uintBitsize))
  19474. if v != nil {
  19475. v[mk] = mv
  19476. }
  19477. }
  19478. dd.ReadMapEnd()
  19479. return v, changed
  19480. }
  19481. func (d *Decoder) fastpathDecMapFloat64Uint8R(f *codecFnInfo, rv reflect.Value) {
  19482. if rv.Kind() == reflect.Ptr {
  19483. vp := rv2i(rv).(*map[float64]uint8)
  19484. if v, changed := fastpathTV.DecMapFloat64Uint8V(*vp, true, d); changed {
  19485. *vp = v
  19486. }
  19487. return
  19488. }
  19489. fastpathTV.DecMapFloat64Uint8V(rv2i(rv).(map[float64]uint8), false, d)
  19490. }
  19491. func (f fastpathT) DecMapFloat64Uint8X(vp *map[float64]uint8, d *Decoder) {
  19492. if v, changed := f.DecMapFloat64Uint8V(*vp, true, d); changed {
  19493. *vp = v
  19494. }
  19495. }
  19496. func (_ fastpathT) DecMapFloat64Uint8V(v map[float64]uint8, canChange bool,
  19497. d *Decoder) (_ map[float64]uint8, changed bool) {
  19498. dd, esep := d.d, d.hh.hasElemSeparators()
  19499. containerLen := dd.ReadMapStart()
  19500. if canChange && v == nil {
  19501. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  19502. v = make(map[float64]uint8, xlen)
  19503. changed = true
  19504. }
  19505. if containerLen == 0 {
  19506. dd.ReadMapEnd()
  19507. return v, changed
  19508. }
  19509. var mk float64
  19510. var mv uint8
  19511. hasLen := containerLen > 0
  19512. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19513. if esep {
  19514. dd.ReadMapElemKey()
  19515. }
  19516. mk = dd.DecodeFloat(false)
  19517. if esep {
  19518. dd.ReadMapElemValue()
  19519. }
  19520. if dd.TryDecodeAsNil() {
  19521. if d.h.DeleteOnNilMapValue {
  19522. delete(v, mk)
  19523. } else {
  19524. v[mk] = 0
  19525. }
  19526. continue
  19527. }
  19528. mv = uint8(dd.DecodeUint(8))
  19529. if v != nil {
  19530. v[mk] = mv
  19531. }
  19532. }
  19533. dd.ReadMapEnd()
  19534. return v, changed
  19535. }
  19536. func (d *Decoder) fastpathDecMapFloat64Uint16R(f *codecFnInfo, rv reflect.Value) {
  19537. if rv.Kind() == reflect.Ptr {
  19538. vp := rv2i(rv).(*map[float64]uint16)
  19539. if v, changed := fastpathTV.DecMapFloat64Uint16V(*vp, true, d); changed {
  19540. *vp = v
  19541. }
  19542. return
  19543. }
  19544. fastpathTV.DecMapFloat64Uint16V(rv2i(rv).(map[float64]uint16), false, d)
  19545. }
  19546. func (f fastpathT) DecMapFloat64Uint16X(vp *map[float64]uint16, d *Decoder) {
  19547. if v, changed := f.DecMapFloat64Uint16V(*vp, true, d); changed {
  19548. *vp = v
  19549. }
  19550. }
  19551. func (_ fastpathT) DecMapFloat64Uint16V(v map[float64]uint16, canChange bool,
  19552. d *Decoder) (_ map[float64]uint16, changed bool) {
  19553. dd, esep := d.d, d.hh.hasElemSeparators()
  19554. containerLen := dd.ReadMapStart()
  19555. if canChange && v == nil {
  19556. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  19557. v = make(map[float64]uint16, xlen)
  19558. changed = true
  19559. }
  19560. if containerLen == 0 {
  19561. dd.ReadMapEnd()
  19562. return v, changed
  19563. }
  19564. var mk float64
  19565. var mv uint16
  19566. hasLen := containerLen > 0
  19567. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19568. if esep {
  19569. dd.ReadMapElemKey()
  19570. }
  19571. mk = dd.DecodeFloat(false)
  19572. if esep {
  19573. dd.ReadMapElemValue()
  19574. }
  19575. if dd.TryDecodeAsNil() {
  19576. if d.h.DeleteOnNilMapValue {
  19577. delete(v, mk)
  19578. } else {
  19579. v[mk] = 0
  19580. }
  19581. continue
  19582. }
  19583. mv = uint16(dd.DecodeUint(16))
  19584. if v != nil {
  19585. v[mk] = mv
  19586. }
  19587. }
  19588. dd.ReadMapEnd()
  19589. return v, changed
  19590. }
  19591. func (d *Decoder) fastpathDecMapFloat64Uint32R(f *codecFnInfo, rv reflect.Value) {
  19592. if rv.Kind() == reflect.Ptr {
  19593. vp := rv2i(rv).(*map[float64]uint32)
  19594. if v, changed := fastpathTV.DecMapFloat64Uint32V(*vp, true, d); changed {
  19595. *vp = v
  19596. }
  19597. return
  19598. }
  19599. fastpathTV.DecMapFloat64Uint32V(rv2i(rv).(map[float64]uint32), false, d)
  19600. }
  19601. func (f fastpathT) DecMapFloat64Uint32X(vp *map[float64]uint32, d *Decoder) {
  19602. if v, changed := f.DecMapFloat64Uint32V(*vp, true, d); changed {
  19603. *vp = v
  19604. }
  19605. }
  19606. func (_ fastpathT) DecMapFloat64Uint32V(v map[float64]uint32, canChange bool,
  19607. d *Decoder) (_ map[float64]uint32, changed bool) {
  19608. dd, esep := d.d, d.hh.hasElemSeparators()
  19609. containerLen := dd.ReadMapStart()
  19610. if canChange && v == nil {
  19611. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  19612. v = make(map[float64]uint32, xlen)
  19613. changed = true
  19614. }
  19615. if containerLen == 0 {
  19616. dd.ReadMapEnd()
  19617. return v, changed
  19618. }
  19619. var mk float64
  19620. var mv uint32
  19621. hasLen := containerLen > 0
  19622. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19623. if esep {
  19624. dd.ReadMapElemKey()
  19625. }
  19626. mk = dd.DecodeFloat(false)
  19627. if esep {
  19628. dd.ReadMapElemValue()
  19629. }
  19630. if dd.TryDecodeAsNil() {
  19631. if d.h.DeleteOnNilMapValue {
  19632. delete(v, mk)
  19633. } else {
  19634. v[mk] = 0
  19635. }
  19636. continue
  19637. }
  19638. mv = uint32(dd.DecodeUint(32))
  19639. if v != nil {
  19640. v[mk] = mv
  19641. }
  19642. }
  19643. dd.ReadMapEnd()
  19644. return v, changed
  19645. }
  19646. func (d *Decoder) fastpathDecMapFloat64Uint64R(f *codecFnInfo, rv reflect.Value) {
  19647. if rv.Kind() == reflect.Ptr {
  19648. vp := rv2i(rv).(*map[float64]uint64)
  19649. if v, changed := fastpathTV.DecMapFloat64Uint64V(*vp, true, d); changed {
  19650. *vp = v
  19651. }
  19652. return
  19653. }
  19654. fastpathTV.DecMapFloat64Uint64V(rv2i(rv).(map[float64]uint64), false, d)
  19655. }
  19656. func (f fastpathT) DecMapFloat64Uint64X(vp *map[float64]uint64, d *Decoder) {
  19657. if v, changed := f.DecMapFloat64Uint64V(*vp, true, d); changed {
  19658. *vp = v
  19659. }
  19660. }
  19661. func (_ fastpathT) DecMapFloat64Uint64V(v map[float64]uint64, canChange bool,
  19662. d *Decoder) (_ map[float64]uint64, changed bool) {
  19663. dd, esep := d.d, d.hh.hasElemSeparators()
  19664. containerLen := dd.ReadMapStart()
  19665. if canChange && v == nil {
  19666. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  19667. v = make(map[float64]uint64, xlen)
  19668. changed = true
  19669. }
  19670. if containerLen == 0 {
  19671. dd.ReadMapEnd()
  19672. return v, changed
  19673. }
  19674. var mk float64
  19675. var mv uint64
  19676. hasLen := containerLen > 0
  19677. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19678. if esep {
  19679. dd.ReadMapElemKey()
  19680. }
  19681. mk = dd.DecodeFloat(false)
  19682. if esep {
  19683. dd.ReadMapElemValue()
  19684. }
  19685. if dd.TryDecodeAsNil() {
  19686. if d.h.DeleteOnNilMapValue {
  19687. delete(v, mk)
  19688. } else {
  19689. v[mk] = 0
  19690. }
  19691. continue
  19692. }
  19693. mv = dd.DecodeUint(64)
  19694. if v != nil {
  19695. v[mk] = mv
  19696. }
  19697. }
  19698. dd.ReadMapEnd()
  19699. return v, changed
  19700. }
  19701. func (d *Decoder) fastpathDecMapFloat64UintptrR(f *codecFnInfo, rv reflect.Value) {
  19702. if rv.Kind() == reflect.Ptr {
  19703. vp := rv2i(rv).(*map[float64]uintptr)
  19704. if v, changed := fastpathTV.DecMapFloat64UintptrV(*vp, true, d); changed {
  19705. *vp = v
  19706. }
  19707. return
  19708. }
  19709. fastpathTV.DecMapFloat64UintptrV(rv2i(rv).(map[float64]uintptr), false, d)
  19710. }
  19711. func (f fastpathT) DecMapFloat64UintptrX(vp *map[float64]uintptr, d *Decoder) {
  19712. if v, changed := f.DecMapFloat64UintptrV(*vp, true, d); changed {
  19713. *vp = v
  19714. }
  19715. }
  19716. func (_ fastpathT) DecMapFloat64UintptrV(v map[float64]uintptr, canChange bool,
  19717. d *Decoder) (_ map[float64]uintptr, changed bool) {
  19718. dd, esep := d.d, d.hh.hasElemSeparators()
  19719. containerLen := dd.ReadMapStart()
  19720. if canChange && v == nil {
  19721. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  19722. v = make(map[float64]uintptr, xlen)
  19723. changed = true
  19724. }
  19725. if containerLen == 0 {
  19726. dd.ReadMapEnd()
  19727. return v, changed
  19728. }
  19729. var mk float64
  19730. var mv uintptr
  19731. hasLen := containerLen > 0
  19732. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19733. if esep {
  19734. dd.ReadMapElemKey()
  19735. }
  19736. mk = dd.DecodeFloat(false)
  19737. if esep {
  19738. dd.ReadMapElemValue()
  19739. }
  19740. if dd.TryDecodeAsNil() {
  19741. if d.h.DeleteOnNilMapValue {
  19742. delete(v, mk)
  19743. } else {
  19744. v[mk] = 0
  19745. }
  19746. continue
  19747. }
  19748. mv = uintptr(dd.DecodeUint(uintBitsize))
  19749. if v != nil {
  19750. v[mk] = mv
  19751. }
  19752. }
  19753. dd.ReadMapEnd()
  19754. return v, changed
  19755. }
  19756. func (d *Decoder) fastpathDecMapFloat64IntR(f *codecFnInfo, rv reflect.Value) {
  19757. if rv.Kind() == reflect.Ptr {
  19758. vp := rv2i(rv).(*map[float64]int)
  19759. if v, changed := fastpathTV.DecMapFloat64IntV(*vp, true, d); changed {
  19760. *vp = v
  19761. }
  19762. return
  19763. }
  19764. fastpathTV.DecMapFloat64IntV(rv2i(rv).(map[float64]int), false, d)
  19765. }
  19766. func (f fastpathT) DecMapFloat64IntX(vp *map[float64]int, d *Decoder) {
  19767. if v, changed := f.DecMapFloat64IntV(*vp, true, d); changed {
  19768. *vp = v
  19769. }
  19770. }
  19771. func (_ fastpathT) DecMapFloat64IntV(v map[float64]int, canChange bool,
  19772. d *Decoder) (_ map[float64]int, changed bool) {
  19773. dd, esep := d.d, d.hh.hasElemSeparators()
  19774. containerLen := dd.ReadMapStart()
  19775. if canChange && v == nil {
  19776. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  19777. v = make(map[float64]int, xlen)
  19778. changed = true
  19779. }
  19780. if containerLen == 0 {
  19781. dd.ReadMapEnd()
  19782. return v, changed
  19783. }
  19784. var mk float64
  19785. var mv int
  19786. hasLen := containerLen > 0
  19787. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19788. if esep {
  19789. dd.ReadMapElemKey()
  19790. }
  19791. mk = dd.DecodeFloat(false)
  19792. if esep {
  19793. dd.ReadMapElemValue()
  19794. }
  19795. if dd.TryDecodeAsNil() {
  19796. if d.h.DeleteOnNilMapValue {
  19797. delete(v, mk)
  19798. } else {
  19799. v[mk] = 0
  19800. }
  19801. continue
  19802. }
  19803. mv = int(dd.DecodeInt(intBitsize))
  19804. if v != nil {
  19805. v[mk] = mv
  19806. }
  19807. }
  19808. dd.ReadMapEnd()
  19809. return v, changed
  19810. }
  19811. func (d *Decoder) fastpathDecMapFloat64Int8R(f *codecFnInfo, rv reflect.Value) {
  19812. if rv.Kind() == reflect.Ptr {
  19813. vp := rv2i(rv).(*map[float64]int8)
  19814. if v, changed := fastpathTV.DecMapFloat64Int8V(*vp, true, d); changed {
  19815. *vp = v
  19816. }
  19817. return
  19818. }
  19819. fastpathTV.DecMapFloat64Int8V(rv2i(rv).(map[float64]int8), false, d)
  19820. }
  19821. func (f fastpathT) DecMapFloat64Int8X(vp *map[float64]int8, d *Decoder) {
  19822. if v, changed := f.DecMapFloat64Int8V(*vp, true, d); changed {
  19823. *vp = v
  19824. }
  19825. }
  19826. func (_ fastpathT) DecMapFloat64Int8V(v map[float64]int8, canChange bool,
  19827. d *Decoder) (_ map[float64]int8, changed bool) {
  19828. dd, esep := d.d, d.hh.hasElemSeparators()
  19829. containerLen := dd.ReadMapStart()
  19830. if canChange && v == nil {
  19831. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  19832. v = make(map[float64]int8, xlen)
  19833. changed = true
  19834. }
  19835. if containerLen == 0 {
  19836. dd.ReadMapEnd()
  19837. return v, changed
  19838. }
  19839. var mk float64
  19840. var mv int8
  19841. hasLen := containerLen > 0
  19842. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19843. if esep {
  19844. dd.ReadMapElemKey()
  19845. }
  19846. mk = dd.DecodeFloat(false)
  19847. if esep {
  19848. dd.ReadMapElemValue()
  19849. }
  19850. if dd.TryDecodeAsNil() {
  19851. if d.h.DeleteOnNilMapValue {
  19852. delete(v, mk)
  19853. } else {
  19854. v[mk] = 0
  19855. }
  19856. continue
  19857. }
  19858. mv = int8(dd.DecodeInt(8))
  19859. if v != nil {
  19860. v[mk] = mv
  19861. }
  19862. }
  19863. dd.ReadMapEnd()
  19864. return v, changed
  19865. }
  19866. func (d *Decoder) fastpathDecMapFloat64Int16R(f *codecFnInfo, rv reflect.Value) {
  19867. if rv.Kind() == reflect.Ptr {
  19868. vp := rv2i(rv).(*map[float64]int16)
  19869. if v, changed := fastpathTV.DecMapFloat64Int16V(*vp, true, d); changed {
  19870. *vp = v
  19871. }
  19872. return
  19873. }
  19874. fastpathTV.DecMapFloat64Int16V(rv2i(rv).(map[float64]int16), false, d)
  19875. }
  19876. func (f fastpathT) DecMapFloat64Int16X(vp *map[float64]int16, d *Decoder) {
  19877. if v, changed := f.DecMapFloat64Int16V(*vp, true, d); changed {
  19878. *vp = v
  19879. }
  19880. }
  19881. func (_ fastpathT) DecMapFloat64Int16V(v map[float64]int16, canChange bool,
  19882. d *Decoder) (_ map[float64]int16, changed bool) {
  19883. dd, esep := d.d, d.hh.hasElemSeparators()
  19884. containerLen := dd.ReadMapStart()
  19885. if canChange && v == nil {
  19886. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  19887. v = make(map[float64]int16, xlen)
  19888. changed = true
  19889. }
  19890. if containerLen == 0 {
  19891. dd.ReadMapEnd()
  19892. return v, changed
  19893. }
  19894. var mk float64
  19895. var mv int16
  19896. hasLen := containerLen > 0
  19897. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19898. if esep {
  19899. dd.ReadMapElemKey()
  19900. }
  19901. mk = dd.DecodeFloat(false)
  19902. if esep {
  19903. dd.ReadMapElemValue()
  19904. }
  19905. if dd.TryDecodeAsNil() {
  19906. if d.h.DeleteOnNilMapValue {
  19907. delete(v, mk)
  19908. } else {
  19909. v[mk] = 0
  19910. }
  19911. continue
  19912. }
  19913. mv = int16(dd.DecodeInt(16))
  19914. if v != nil {
  19915. v[mk] = mv
  19916. }
  19917. }
  19918. dd.ReadMapEnd()
  19919. return v, changed
  19920. }
  19921. func (d *Decoder) fastpathDecMapFloat64Int32R(f *codecFnInfo, rv reflect.Value) {
  19922. if rv.Kind() == reflect.Ptr {
  19923. vp := rv2i(rv).(*map[float64]int32)
  19924. if v, changed := fastpathTV.DecMapFloat64Int32V(*vp, true, d); changed {
  19925. *vp = v
  19926. }
  19927. return
  19928. }
  19929. fastpathTV.DecMapFloat64Int32V(rv2i(rv).(map[float64]int32), false, d)
  19930. }
  19931. func (f fastpathT) DecMapFloat64Int32X(vp *map[float64]int32, d *Decoder) {
  19932. if v, changed := f.DecMapFloat64Int32V(*vp, true, d); changed {
  19933. *vp = v
  19934. }
  19935. }
  19936. func (_ fastpathT) DecMapFloat64Int32V(v map[float64]int32, canChange bool,
  19937. d *Decoder) (_ map[float64]int32, changed bool) {
  19938. dd, esep := d.d, d.hh.hasElemSeparators()
  19939. containerLen := dd.ReadMapStart()
  19940. if canChange && v == nil {
  19941. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  19942. v = make(map[float64]int32, xlen)
  19943. changed = true
  19944. }
  19945. if containerLen == 0 {
  19946. dd.ReadMapEnd()
  19947. return v, changed
  19948. }
  19949. var mk float64
  19950. var mv int32
  19951. hasLen := containerLen > 0
  19952. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19953. if esep {
  19954. dd.ReadMapElemKey()
  19955. }
  19956. mk = dd.DecodeFloat(false)
  19957. if esep {
  19958. dd.ReadMapElemValue()
  19959. }
  19960. if dd.TryDecodeAsNil() {
  19961. if d.h.DeleteOnNilMapValue {
  19962. delete(v, mk)
  19963. } else {
  19964. v[mk] = 0
  19965. }
  19966. continue
  19967. }
  19968. mv = int32(dd.DecodeInt(32))
  19969. if v != nil {
  19970. v[mk] = mv
  19971. }
  19972. }
  19973. dd.ReadMapEnd()
  19974. return v, changed
  19975. }
  19976. func (d *Decoder) fastpathDecMapFloat64Int64R(f *codecFnInfo, rv reflect.Value) {
  19977. if rv.Kind() == reflect.Ptr {
  19978. vp := rv2i(rv).(*map[float64]int64)
  19979. if v, changed := fastpathTV.DecMapFloat64Int64V(*vp, true, d); changed {
  19980. *vp = v
  19981. }
  19982. return
  19983. }
  19984. fastpathTV.DecMapFloat64Int64V(rv2i(rv).(map[float64]int64), false, d)
  19985. }
  19986. func (f fastpathT) DecMapFloat64Int64X(vp *map[float64]int64, d *Decoder) {
  19987. if v, changed := f.DecMapFloat64Int64V(*vp, true, d); changed {
  19988. *vp = v
  19989. }
  19990. }
  19991. func (_ fastpathT) DecMapFloat64Int64V(v map[float64]int64, canChange bool,
  19992. d *Decoder) (_ map[float64]int64, changed bool) {
  19993. dd, esep := d.d, d.hh.hasElemSeparators()
  19994. containerLen := dd.ReadMapStart()
  19995. if canChange && v == nil {
  19996. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  19997. v = make(map[float64]int64, xlen)
  19998. changed = true
  19999. }
  20000. if containerLen == 0 {
  20001. dd.ReadMapEnd()
  20002. return v, changed
  20003. }
  20004. var mk float64
  20005. var mv int64
  20006. hasLen := containerLen > 0
  20007. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20008. if esep {
  20009. dd.ReadMapElemKey()
  20010. }
  20011. mk = dd.DecodeFloat(false)
  20012. if esep {
  20013. dd.ReadMapElemValue()
  20014. }
  20015. if dd.TryDecodeAsNil() {
  20016. if d.h.DeleteOnNilMapValue {
  20017. delete(v, mk)
  20018. } else {
  20019. v[mk] = 0
  20020. }
  20021. continue
  20022. }
  20023. mv = dd.DecodeInt(64)
  20024. if v != nil {
  20025. v[mk] = mv
  20026. }
  20027. }
  20028. dd.ReadMapEnd()
  20029. return v, changed
  20030. }
  20031. func (d *Decoder) fastpathDecMapFloat64Float32R(f *codecFnInfo, rv reflect.Value) {
  20032. if rv.Kind() == reflect.Ptr {
  20033. vp := rv2i(rv).(*map[float64]float32)
  20034. if v, changed := fastpathTV.DecMapFloat64Float32V(*vp, true, d); changed {
  20035. *vp = v
  20036. }
  20037. return
  20038. }
  20039. fastpathTV.DecMapFloat64Float32V(rv2i(rv).(map[float64]float32), false, d)
  20040. }
  20041. func (f fastpathT) DecMapFloat64Float32X(vp *map[float64]float32, d *Decoder) {
  20042. if v, changed := f.DecMapFloat64Float32V(*vp, true, d); changed {
  20043. *vp = v
  20044. }
  20045. }
  20046. func (_ fastpathT) DecMapFloat64Float32V(v map[float64]float32, canChange bool,
  20047. d *Decoder) (_ map[float64]float32, changed bool) {
  20048. dd, esep := d.d, d.hh.hasElemSeparators()
  20049. containerLen := dd.ReadMapStart()
  20050. if canChange && v == nil {
  20051. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  20052. v = make(map[float64]float32, xlen)
  20053. changed = true
  20054. }
  20055. if containerLen == 0 {
  20056. dd.ReadMapEnd()
  20057. return v, changed
  20058. }
  20059. var mk float64
  20060. var mv float32
  20061. hasLen := containerLen > 0
  20062. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20063. if esep {
  20064. dd.ReadMapElemKey()
  20065. }
  20066. mk = dd.DecodeFloat(false)
  20067. if esep {
  20068. dd.ReadMapElemValue()
  20069. }
  20070. if dd.TryDecodeAsNil() {
  20071. if d.h.DeleteOnNilMapValue {
  20072. delete(v, mk)
  20073. } else {
  20074. v[mk] = 0
  20075. }
  20076. continue
  20077. }
  20078. mv = float32(dd.DecodeFloat(true))
  20079. if v != nil {
  20080. v[mk] = mv
  20081. }
  20082. }
  20083. dd.ReadMapEnd()
  20084. return v, changed
  20085. }
  20086. func (d *Decoder) fastpathDecMapFloat64Float64R(f *codecFnInfo, rv reflect.Value) {
  20087. if rv.Kind() == reflect.Ptr {
  20088. vp := rv2i(rv).(*map[float64]float64)
  20089. if v, changed := fastpathTV.DecMapFloat64Float64V(*vp, true, d); changed {
  20090. *vp = v
  20091. }
  20092. return
  20093. }
  20094. fastpathTV.DecMapFloat64Float64V(rv2i(rv).(map[float64]float64), false, d)
  20095. }
  20096. func (f fastpathT) DecMapFloat64Float64X(vp *map[float64]float64, d *Decoder) {
  20097. if v, changed := f.DecMapFloat64Float64V(*vp, true, d); changed {
  20098. *vp = v
  20099. }
  20100. }
  20101. func (_ fastpathT) DecMapFloat64Float64V(v map[float64]float64, canChange bool,
  20102. d *Decoder) (_ map[float64]float64, changed bool) {
  20103. dd, esep := d.d, d.hh.hasElemSeparators()
  20104. containerLen := dd.ReadMapStart()
  20105. if canChange && v == nil {
  20106. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  20107. v = make(map[float64]float64, xlen)
  20108. changed = true
  20109. }
  20110. if containerLen == 0 {
  20111. dd.ReadMapEnd()
  20112. return v, changed
  20113. }
  20114. var mk float64
  20115. var mv float64
  20116. hasLen := containerLen > 0
  20117. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20118. if esep {
  20119. dd.ReadMapElemKey()
  20120. }
  20121. mk = dd.DecodeFloat(false)
  20122. if esep {
  20123. dd.ReadMapElemValue()
  20124. }
  20125. if dd.TryDecodeAsNil() {
  20126. if d.h.DeleteOnNilMapValue {
  20127. delete(v, mk)
  20128. } else {
  20129. v[mk] = 0
  20130. }
  20131. continue
  20132. }
  20133. mv = dd.DecodeFloat(false)
  20134. if v != nil {
  20135. v[mk] = mv
  20136. }
  20137. }
  20138. dd.ReadMapEnd()
  20139. return v, changed
  20140. }
  20141. func (d *Decoder) fastpathDecMapFloat64BoolR(f *codecFnInfo, rv reflect.Value) {
  20142. if rv.Kind() == reflect.Ptr {
  20143. vp := rv2i(rv).(*map[float64]bool)
  20144. if v, changed := fastpathTV.DecMapFloat64BoolV(*vp, true, d); changed {
  20145. *vp = v
  20146. }
  20147. return
  20148. }
  20149. fastpathTV.DecMapFloat64BoolV(rv2i(rv).(map[float64]bool), false, d)
  20150. }
  20151. func (f fastpathT) DecMapFloat64BoolX(vp *map[float64]bool, d *Decoder) {
  20152. if v, changed := f.DecMapFloat64BoolV(*vp, true, d); changed {
  20153. *vp = v
  20154. }
  20155. }
  20156. func (_ fastpathT) DecMapFloat64BoolV(v map[float64]bool, canChange bool,
  20157. d *Decoder) (_ map[float64]bool, changed bool) {
  20158. dd, esep := d.d, d.hh.hasElemSeparators()
  20159. containerLen := dd.ReadMapStart()
  20160. if canChange && v == nil {
  20161. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  20162. v = make(map[float64]bool, xlen)
  20163. changed = true
  20164. }
  20165. if containerLen == 0 {
  20166. dd.ReadMapEnd()
  20167. return v, changed
  20168. }
  20169. var mk float64
  20170. var mv bool
  20171. hasLen := containerLen > 0
  20172. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20173. if esep {
  20174. dd.ReadMapElemKey()
  20175. }
  20176. mk = dd.DecodeFloat(false)
  20177. if esep {
  20178. dd.ReadMapElemValue()
  20179. }
  20180. if dd.TryDecodeAsNil() {
  20181. if d.h.DeleteOnNilMapValue {
  20182. delete(v, mk)
  20183. } else {
  20184. v[mk] = false
  20185. }
  20186. continue
  20187. }
  20188. mv = dd.DecodeBool()
  20189. if v != nil {
  20190. v[mk] = mv
  20191. }
  20192. }
  20193. dd.ReadMapEnd()
  20194. return v, changed
  20195. }
  20196. func (d *Decoder) fastpathDecMapUintIntfR(f *codecFnInfo, rv reflect.Value) {
  20197. if rv.Kind() == reflect.Ptr {
  20198. vp := rv2i(rv).(*map[uint]interface{})
  20199. if v, changed := fastpathTV.DecMapUintIntfV(*vp, true, d); changed {
  20200. *vp = v
  20201. }
  20202. return
  20203. }
  20204. fastpathTV.DecMapUintIntfV(rv2i(rv).(map[uint]interface{}), false, d)
  20205. }
  20206. func (f fastpathT) DecMapUintIntfX(vp *map[uint]interface{}, d *Decoder) {
  20207. if v, changed := f.DecMapUintIntfV(*vp, true, d); changed {
  20208. *vp = v
  20209. }
  20210. }
  20211. func (_ fastpathT) DecMapUintIntfV(v map[uint]interface{}, canChange bool,
  20212. d *Decoder) (_ map[uint]interface{}, changed bool) {
  20213. dd, esep := d.d, d.hh.hasElemSeparators()
  20214. containerLen := dd.ReadMapStart()
  20215. if canChange && v == nil {
  20216. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  20217. v = make(map[uint]interface{}, xlen)
  20218. changed = true
  20219. }
  20220. if containerLen == 0 {
  20221. dd.ReadMapEnd()
  20222. return v, changed
  20223. }
  20224. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  20225. var mk uint
  20226. var mv interface{}
  20227. hasLen := containerLen > 0
  20228. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20229. if esep {
  20230. dd.ReadMapElemKey()
  20231. }
  20232. mk = uint(dd.DecodeUint(uintBitsize))
  20233. if esep {
  20234. dd.ReadMapElemValue()
  20235. }
  20236. if dd.TryDecodeAsNil() {
  20237. if d.h.DeleteOnNilMapValue {
  20238. delete(v, mk)
  20239. } else {
  20240. v[mk] = nil
  20241. }
  20242. continue
  20243. }
  20244. if mapGet {
  20245. mv = v[mk]
  20246. } else {
  20247. mv = nil
  20248. }
  20249. d.decode(&mv)
  20250. if v != nil {
  20251. v[mk] = mv
  20252. }
  20253. }
  20254. dd.ReadMapEnd()
  20255. return v, changed
  20256. }
  20257. func (d *Decoder) fastpathDecMapUintStringR(f *codecFnInfo, rv reflect.Value) {
  20258. if rv.Kind() == reflect.Ptr {
  20259. vp := rv2i(rv).(*map[uint]string)
  20260. if v, changed := fastpathTV.DecMapUintStringV(*vp, true, d); changed {
  20261. *vp = v
  20262. }
  20263. return
  20264. }
  20265. fastpathTV.DecMapUintStringV(rv2i(rv).(map[uint]string), false, d)
  20266. }
  20267. func (f fastpathT) DecMapUintStringX(vp *map[uint]string, d *Decoder) {
  20268. if v, changed := f.DecMapUintStringV(*vp, true, d); changed {
  20269. *vp = v
  20270. }
  20271. }
  20272. func (_ fastpathT) DecMapUintStringV(v map[uint]string, canChange bool,
  20273. d *Decoder) (_ map[uint]string, changed bool) {
  20274. dd, esep := d.d, d.hh.hasElemSeparators()
  20275. containerLen := dd.ReadMapStart()
  20276. if canChange && v == nil {
  20277. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  20278. v = make(map[uint]string, xlen)
  20279. changed = true
  20280. }
  20281. if containerLen == 0 {
  20282. dd.ReadMapEnd()
  20283. return v, changed
  20284. }
  20285. var mk uint
  20286. var mv string
  20287. hasLen := containerLen > 0
  20288. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20289. if esep {
  20290. dd.ReadMapElemKey()
  20291. }
  20292. mk = uint(dd.DecodeUint(uintBitsize))
  20293. if esep {
  20294. dd.ReadMapElemValue()
  20295. }
  20296. if dd.TryDecodeAsNil() {
  20297. if d.h.DeleteOnNilMapValue {
  20298. delete(v, mk)
  20299. } else {
  20300. v[mk] = ""
  20301. }
  20302. continue
  20303. }
  20304. mv = dd.DecodeString()
  20305. if v != nil {
  20306. v[mk] = mv
  20307. }
  20308. }
  20309. dd.ReadMapEnd()
  20310. return v, changed
  20311. }
  20312. func (d *Decoder) fastpathDecMapUintUintR(f *codecFnInfo, rv reflect.Value) {
  20313. if rv.Kind() == reflect.Ptr {
  20314. vp := rv2i(rv).(*map[uint]uint)
  20315. if v, changed := fastpathTV.DecMapUintUintV(*vp, true, d); changed {
  20316. *vp = v
  20317. }
  20318. return
  20319. }
  20320. fastpathTV.DecMapUintUintV(rv2i(rv).(map[uint]uint), false, d)
  20321. }
  20322. func (f fastpathT) DecMapUintUintX(vp *map[uint]uint, d *Decoder) {
  20323. if v, changed := f.DecMapUintUintV(*vp, true, d); changed {
  20324. *vp = v
  20325. }
  20326. }
  20327. func (_ fastpathT) DecMapUintUintV(v map[uint]uint, canChange bool,
  20328. d *Decoder) (_ map[uint]uint, changed bool) {
  20329. dd, esep := d.d, d.hh.hasElemSeparators()
  20330. containerLen := dd.ReadMapStart()
  20331. if canChange && v == nil {
  20332. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  20333. v = make(map[uint]uint, xlen)
  20334. changed = true
  20335. }
  20336. if containerLen == 0 {
  20337. dd.ReadMapEnd()
  20338. return v, changed
  20339. }
  20340. var mk uint
  20341. var mv uint
  20342. hasLen := containerLen > 0
  20343. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20344. if esep {
  20345. dd.ReadMapElemKey()
  20346. }
  20347. mk = uint(dd.DecodeUint(uintBitsize))
  20348. if esep {
  20349. dd.ReadMapElemValue()
  20350. }
  20351. if dd.TryDecodeAsNil() {
  20352. if d.h.DeleteOnNilMapValue {
  20353. delete(v, mk)
  20354. } else {
  20355. v[mk] = 0
  20356. }
  20357. continue
  20358. }
  20359. mv = uint(dd.DecodeUint(uintBitsize))
  20360. if v != nil {
  20361. v[mk] = mv
  20362. }
  20363. }
  20364. dd.ReadMapEnd()
  20365. return v, changed
  20366. }
  20367. func (d *Decoder) fastpathDecMapUintUint8R(f *codecFnInfo, rv reflect.Value) {
  20368. if rv.Kind() == reflect.Ptr {
  20369. vp := rv2i(rv).(*map[uint]uint8)
  20370. if v, changed := fastpathTV.DecMapUintUint8V(*vp, true, d); changed {
  20371. *vp = v
  20372. }
  20373. return
  20374. }
  20375. fastpathTV.DecMapUintUint8V(rv2i(rv).(map[uint]uint8), false, d)
  20376. }
  20377. func (f fastpathT) DecMapUintUint8X(vp *map[uint]uint8, d *Decoder) {
  20378. if v, changed := f.DecMapUintUint8V(*vp, true, d); changed {
  20379. *vp = v
  20380. }
  20381. }
  20382. func (_ fastpathT) DecMapUintUint8V(v map[uint]uint8, canChange bool,
  20383. d *Decoder) (_ map[uint]uint8, changed bool) {
  20384. dd, esep := d.d, d.hh.hasElemSeparators()
  20385. containerLen := dd.ReadMapStart()
  20386. if canChange && v == nil {
  20387. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  20388. v = make(map[uint]uint8, xlen)
  20389. changed = true
  20390. }
  20391. if containerLen == 0 {
  20392. dd.ReadMapEnd()
  20393. return v, changed
  20394. }
  20395. var mk uint
  20396. var mv uint8
  20397. hasLen := containerLen > 0
  20398. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20399. if esep {
  20400. dd.ReadMapElemKey()
  20401. }
  20402. mk = uint(dd.DecodeUint(uintBitsize))
  20403. if esep {
  20404. dd.ReadMapElemValue()
  20405. }
  20406. if dd.TryDecodeAsNil() {
  20407. if d.h.DeleteOnNilMapValue {
  20408. delete(v, mk)
  20409. } else {
  20410. v[mk] = 0
  20411. }
  20412. continue
  20413. }
  20414. mv = uint8(dd.DecodeUint(8))
  20415. if v != nil {
  20416. v[mk] = mv
  20417. }
  20418. }
  20419. dd.ReadMapEnd()
  20420. return v, changed
  20421. }
  20422. func (d *Decoder) fastpathDecMapUintUint16R(f *codecFnInfo, rv reflect.Value) {
  20423. if rv.Kind() == reflect.Ptr {
  20424. vp := rv2i(rv).(*map[uint]uint16)
  20425. if v, changed := fastpathTV.DecMapUintUint16V(*vp, true, d); changed {
  20426. *vp = v
  20427. }
  20428. return
  20429. }
  20430. fastpathTV.DecMapUintUint16V(rv2i(rv).(map[uint]uint16), false, d)
  20431. }
  20432. func (f fastpathT) DecMapUintUint16X(vp *map[uint]uint16, d *Decoder) {
  20433. if v, changed := f.DecMapUintUint16V(*vp, true, d); changed {
  20434. *vp = v
  20435. }
  20436. }
  20437. func (_ fastpathT) DecMapUintUint16V(v map[uint]uint16, canChange bool,
  20438. d *Decoder) (_ map[uint]uint16, changed bool) {
  20439. dd, esep := d.d, d.hh.hasElemSeparators()
  20440. containerLen := dd.ReadMapStart()
  20441. if canChange && v == nil {
  20442. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  20443. v = make(map[uint]uint16, xlen)
  20444. changed = true
  20445. }
  20446. if containerLen == 0 {
  20447. dd.ReadMapEnd()
  20448. return v, changed
  20449. }
  20450. var mk uint
  20451. var mv uint16
  20452. hasLen := containerLen > 0
  20453. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20454. if esep {
  20455. dd.ReadMapElemKey()
  20456. }
  20457. mk = uint(dd.DecodeUint(uintBitsize))
  20458. if esep {
  20459. dd.ReadMapElemValue()
  20460. }
  20461. if dd.TryDecodeAsNil() {
  20462. if d.h.DeleteOnNilMapValue {
  20463. delete(v, mk)
  20464. } else {
  20465. v[mk] = 0
  20466. }
  20467. continue
  20468. }
  20469. mv = uint16(dd.DecodeUint(16))
  20470. if v != nil {
  20471. v[mk] = mv
  20472. }
  20473. }
  20474. dd.ReadMapEnd()
  20475. return v, changed
  20476. }
  20477. func (d *Decoder) fastpathDecMapUintUint32R(f *codecFnInfo, rv reflect.Value) {
  20478. if rv.Kind() == reflect.Ptr {
  20479. vp := rv2i(rv).(*map[uint]uint32)
  20480. if v, changed := fastpathTV.DecMapUintUint32V(*vp, true, d); changed {
  20481. *vp = v
  20482. }
  20483. return
  20484. }
  20485. fastpathTV.DecMapUintUint32V(rv2i(rv).(map[uint]uint32), false, d)
  20486. }
  20487. func (f fastpathT) DecMapUintUint32X(vp *map[uint]uint32, d *Decoder) {
  20488. if v, changed := f.DecMapUintUint32V(*vp, true, d); changed {
  20489. *vp = v
  20490. }
  20491. }
  20492. func (_ fastpathT) DecMapUintUint32V(v map[uint]uint32, canChange bool,
  20493. d *Decoder) (_ map[uint]uint32, changed bool) {
  20494. dd, esep := d.d, d.hh.hasElemSeparators()
  20495. containerLen := dd.ReadMapStart()
  20496. if canChange && v == nil {
  20497. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  20498. v = make(map[uint]uint32, xlen)
  20499. changed = true
  20500. }
  20501. if containerLen == 0 {
  20502. dd.ReadMapEnd()
  20503. return v, changed
  20504. }
  20505. var mk uint
  20506. var mv uint32
  20507. hasLen := containerLen > 0
  20508. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20509. if esep {
  20510. dd.ReadMapElemKey()
  20511. }
  20512. mk = uint(dd.DecodeUint(uintBitsize))
  20513. if esep {
  20514. dd.ReadMapElemValue()
  20515. }
  20516. if dd.TryDecodeAsNil() {
  20517. if d.h.DeleteOnNilMapValue {
  20518. delete(v, mk)
  20519. } else {
  20520. v[mk] = 0
  20521. }
  20522. continue
  20523. }
  20524. mv = uint32(dd.DecodeUint(32))
  20525. if v != nil {
  20526. v[mk] = mv
  20527. }
  20528. }
  20529. dd.ReadMapEnd()
  20530. return v, changed
  20531. }
  20532. func (d *Decoder) fastpathDecMapUintUint64R(f *codecFnInfo, rv reflect.Value) {
  20533. if rv.Kind() == reflect.Ptr {
  20534. vp := rv2i(rv).(*map[uint]uint64)
  20535. if v, changed := fastpathTV.DecMapUintUint64V(*vp, true, d); changed {
  20536. *vp = v
  20537. }
  20538. return
  20539. }
  20540. fastpathTV.DecMapUintUint64V(rv2i(rv).(map[uint]uint64), false, d)
  20541. }
  20542. func (f fastpathT) DecMapUintUint64X(vp *map[uint]uint64, d *Decoder) {
  20543. if v, changed := f.DecMapUintUint64V(*vp, true, d); changed {
  20544. *vp = v
  20545. }
  20546. }
  20547. func (_ fastpathT) DecMapUintUint64V(v map[uint]uint64, canChange bool,
  20548. d *Decoder) (_ map[uint]uint64, changed bool) {
  20549. dd, esep := d.d, d.hh.hasElemSeparators()
  20550. containerLen := dd.ReadMapStart()
  20551. if canChange && v == nil {
  20552. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  20553. v = make(map[uint]uint64, xlen)
  20554. changed = true
  20555. }
  20556. if containerLen == 0 {
  20557. dd.ReadMapEnd()
  20558. return v, changed
  20559. }
  20560. var mk uint
  20561. var mv uint64
  20562. hasLen := containerLen > 0
  20563. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20564. if esep {
  20565. dd.ReadMapElemKey()
  20566. }
  20567. mk = uint(dd.DecodeUint(uintBitsize))
  20568. if esep {
  20569. dd.ReadMapElemValue()
  20570. }
  20571. if dd.TryDecodeAsNil() {
  20572. if d.h.DeleteOnNilMapValue {
  20573. delete(v, mk)
  20574. } else {
  20575. v[mk] = 0
  20576. }
  20577. continue
  20578. }
  20579. mv = dd.DecodeUint(64)
  20580. if v != nil {
  20581. v[mk] = mv
  20582. }
  20583. }
  20584. dd.ReadMapEnd()
  20585. return v, changed
  20586. }
  20587. func (d *Decoder) fastpathDecMapUintUintptrR(f *codecFnInfo, rv reflect.Value) {
  20588. if rv.Kind() == reflect.Ptr {
  20589. vp := rv2i(rv).(*map[uint]uintptr)
  20590. if v, changed := fastpathTV.DecMapUintUintptrV(*vp, true, d); changed {
  20591. *vp = v
  20592. }
  20593. return
  20594. }
  20595. fastpathTV.DecMapUintUintptrV(rv2i(rv).(map[uint]uintptr), false, d)
  20596. }
  20597. func (f fastpathT) DecMapUintUintptrX(vp *map[uint]uintptr, d *Decoder) {
  20598. if v, changed := f.DecMapUintUintptrV(*vp, true, d); changed {
  20599. *vp = v
  20600. }
  20601. }
  20602. func (_ fastpathT) DecMapUintUintptrV(v map[uint]uintptr, canChange bool,
  20603. d *Decoder) (_ map[uint]uintptr, changed bool) {
  20604. dd, esep := d.d, d.hh.hasElemSeparators()
  20605. containerLen := dd.ReadMapStart()
  20606. if canChange && v == nil {
  20607. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  20608. v = make(map[uint]uintptr, xlen)
  20609. changed = true
  20610. }
  20611. if containerLen == 0 {
  20612. dd.ReadMapEnd()
  20613. return v, changed
  20614. }
  20615. var mk uint
  20616. var mv uintptr
  20617. hasLen := containerLen > 0
  20618. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20619. if esep {
  20620. dd.ReadMapElemKey()
  20621. }
  20622. mk = uint(dd.DecodeUint(uintBitsize))
  20623. if esep {
  20624. dd.ReadMapElemValue()
  20625. }
  20626. if dd.TryDecodeAsNil() {
  20627. if d.h.DeleteOnNilMapValue {
  20628. delete(v, mk)
  20629. } else {
  20630. v[mk] = 0
  20631. }
  20632. continue
  20633. }
  20634. mv = uintptr(dd.DecodeUint(uintBitsize))
  20635. if v != nil {
  20636. v[mk] = mv
  20637. }
  20638. }
  20639. dd.ReadMapEnd()
  20640. return v, changed
  20641. }
  20642. func (d *Decoder) fastpathDecMapUintIntR(f *codecFnInfo, rv reflect.Value) {
  20643. if rv.Kind() == reflect.Ptr {
  20644. vp := rv2i(rv).(*map[uint]int)
  20645. if v, changed := fastpathTV.DecMapUintIntV(*vp, true, d); changed {
  20646. *vp = v
  20647. }
  20648. return
  20649. }
  20650. fastpathTV.DecMapUintIntV(rv2i(rv).(map[uint]int), false, d)
  20651. }
  20652. func (f fastpathT) DecMapUintIntX(vp *map[uint]int, d *Decoder) {
  20653. if v, changed := f.DecMapUintIntV(*vp, true, d); changed {
  20654. *vp = v
  20655. }
  20656. }
  20657. func (_ fastpathT) DecMapUintIntV(v map[uint]int, canChange bool,
  20658. d *Decoder) (_ map[uint]int, changed bool) {
  20659. dd, esep := d.d, d.hh.hasElemSeparators()
  20660. containerLen := dd.ReadMapStart()
  20661. if canChange && v == nil {
  20662. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  20663. v = make(map[uint]int, xlen)
  20664. changed = true
  20665. }
  20666. if containerLen == 0 {
  20667. dd.ReadMapEnd()
  20668. return v, changed
  20669. }
  20670. var mk uint
  20671. var mv int
  20672. hasLen := containerLen > 0
  20673. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20674. if esep {
  20675. dd.ReadMapElemKey()
  20676. }
  20677. mk = uint(dd.DecodeUint(uintBitsize))
  20678. if esep {
  20679. dd.ReadMapElemValue()
  20680. }
  20681. if dd.TryDecodeAsNil() {
  20682. if d.h.DeleteOnNilMapValue {
  20683. delete(v, mk)
  20684. } else {
  20685. v[mk] = 0
  20686. }
  20687. continue
  20688. }
  20689. mv = int(dd.DecodeInt(intBitsize))
  20690. if v != nil {
  20691. v[mk] = mv
  20692. }
  20693. }
  20694. dd.ReadMapEnd()
  20695. return v, changed
  20696. }
  20697. func (d *Decoder) fastpathDecMapUintInt8R(f *codecFnInfo, rv reflect.Value) {
  20698. if rv.Kind() == reflect.Ptr {
  20699. vp := rv2i(rv).(*map[uint]int8)
  20700. if v, changed := fastpathTV.DecMapUintInt8V(*vp, true, d); changed {
  20701. *vp = v
  20702. }
  20703. return
  20704. }
  20705. fastpathTV.DecMapUintInt8V(rv2i(rv).(map[uint]int8), false, d)
  20706. }
  20707. func (f fastpathT) DecMapUintInt8X(vp *map[uint]int8, d *Decoder) {
  20708. if v, changed := f.DecMapUintInt8V(*vp, true, d); changed {
  20709. *vp = v
  20710. }
  20711. }
  20712. func (_ fastpathT) DecMapUintInt8V(v map[uint]int8, canChange bool,
  20713. d *Decoder) (_ map[uint]int8, changed bool) {
  20714. dd, esep := d.d, d.hh.hasElemSeparators()
  20715. containerLen := dd.ReadMapStart()
  20716. if canChange && v == nil {
  20717. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  20718. v = make(map[uint]int8, xlen)
  20719. changed = true
  20720. }
  20721. if containerLen == 0 {
  20722. dd.ReadMapEnd()
  20723. return v, changed
  20724. }
  20725. var mk uint
  20726. var mv int8
  20727. hasLen := containerLen > 0
  20728. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20729. if esep {
  20730. dd.ReadMapElemKey()
  20731. }
  20732. mk = uint(dd.DecodeUint(uintBitsize))
  20733. if esep {
  20734. dd.ReadMapElemValue()
  20735. }
  20736. if dd.TryDecodeAsNil() {
  20737. if d.h.DeleteOnNilMapValue {
  20738. delete(v, mk)
  20739. } else {
  20740. v[mk] = 0
  20741. }
  20742. continue
  20743. }
  20744. mv = int8(dd.DecodeInt(8))
  20745. if v != nil {
  20746. v[mk] = mv
  20747. }
  20748. }
  20749. dd.ReadMapEnd()
  20750. return v, changed
  20751. }
  20752. func (d *Decoder) fastpathDecMapUintInt16R(f *codecFnInfo, rv reflect.Value) {
  20753. if rv.Kind() == reflect.Ptr {
  20754. vp := rv2i(rv).(*map[uint]int16)
  20755. if v, changed := fastpathTV.DecMapUintInt16V(*vp, true, d); changed {
  20756. *vp = v
  20757. }
  20758. return
  20759. }
  20760. fastpathTV.DecMapUintInt16V(rv2i(rv).(map[uint]int16), false, d)
  20761. }
  20762. func (f fastpathT) DecMapUintInt16X(vp *map[uint]int16, d *Decoder) {
  20763. if v, changed := f.DecMapUintInt16V(*vp, true, d); changed {
  20764. *vp = v
  20765. }
  20766. }
  20767. func (_ fastpathT) DecMapUintInt16V(v map[uint]int16, canChange bool,
  20768. d *Decoder) (_ map[uint]int16, changed bool) {
  20769. dd, esep := d.d, d.hh.hasElemSeparators()
  20770. containerLen := dd.ReadMapStart()
  20771. if canChange && v == nil {
  20772. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  20773. v = make(map[uint]int16, xlen)
  20774. changed = true
  20775. }
  20776. if containerLen == 0 {
  20777. dd.ReadMapEnd()
  20778. return v, changed
  20779. }
  20780. var mk uint
  20781. var mv int16
  20782. hasLen := containerLen > 0
  20783. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20784. if esep {
  20785. dd.ReadMapElemKey()
  20786. }
  20787. mk = uint(dd.DecodeUint(uintBitsize))
  20788. if esep {
  20789. dd.ReadMapElemValue()
  20790. }
  20791. if dd.TryDecodeAsNil() {
  20792. if d.h.DeleteOnNilMapValue {
  20793. delete(v, mk)
  20794. } else {
  20795. v[mk] = 0
  20796. }
  20797. continue
  20798. }
  20799. mv = int16(dd.DecodeInt(16))
  20800. if v != nil {
  20801. v[mk] = mv
  20802. }
  20803. }
  20804. dd.ReadMapEnd()
  20805. return v, changed
  20806. }
  20807. func (d *Decoder) fastpathDecMapUintInt32R(f *codecFnInfo, rv reflect.Value) {
  20808. if rv.Kind() == reflect.Ptr {
  20809. vp := rv2i(rv).(*map[uint]int32)
  20810. if v, changed := fastpathTV.DecMapUintInt32V(*vp, true, d); changed {
  20811. *vp = v
  20812. }
  20813. return
  20814. }
  20815. fastpathTV.DecMapUintInt32V(rv2i(rv).(map[uint]int32), false, d)
  20816. }
  20817. func (f fastpathT) DecMapUintInt32X(vp *map[uint]int32, d *Decoder) {
  20818. if v, changed := f.DecMapUintInt32V(*vp, true, d); changed {
  20819. *vp = v
  20820. }
  20821. }
  20822. func (_ fastpathT) DecMapUintInt32V(v map[uint]int32, canChange bool,
  20823. d *Decoder) (_ map[uint]int32, changed bool) {
  20824. dd, esep := d.d, d.hh.hasElemSeparators()
  20825. containerLen := dd.ReadMapStart()
  20826. if canChange && v == nil {
  20827. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  20828. v = make(map[uint]int32, xlen)
  20829. changed = true
  20830. }
  20831. if containerLen == 0 {
  20832. dd.ReadMapEnd()
  20833. return v, changed
  20834. }
  20835. var mk uint
  20836. var mv int32
  20837. hasLen := containerLen > 0
  20838. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20839. if esep {
  20840. dd.ReadMapElemKey()
  20841. }
  20842. mk = uint(dd.DecodeUint(uintBitsize))
  20843. if esep {
  20844. dd.ReadMapElemValue()
  20845. }
  20846. if dd.TryDecodeAsNil() {
  20847. if d.h.DeleteOnNilMapValue {
  20848. delete(v, mk)
  20849. } else {
  20850. v[mk] = 0
  20851. }
  20852. continue
  20853. }
  20854. mv = int32(dd.DecodeInt(32))
  20855. if v != nil {
  20856. v[mk] = mv
  20857. }
  20858. }
  20859. dd.ReadMapEnd()
  20860. return v, changed
  20861. }
  20862. func (d *Decoder) fastpathDecMapUintInt64R(f *codecFnInfo, rv reflect.Value) {
  20863. if rv.Kind() == reflect.Ptr {
  20864. vp := rv2i(rv).(*map[uint]int64)
  20865. if v, changed := fastpathTV.DecMapUintInt64V(*vp, true, d); changed {
  20866. *vp = v
  20867. }
  20868. return
  20869. }
  20870. fastpathTV.DecMapUintInt64V(rv2i(rv).(map[uint]int64), false, d)
  20871. }
  20872. func (f fastpathT) DecMapUintInt64X(vp *map[uint]int64, d *Decoder) {
  20873. if v, changed := f.DecMapUintInt64V(*vp, true, d); changed {
  20874. *vp = v
  20875. }
  20876. }
  20877. func (_ fastpathT) DecMapUintInt64V(v map[uint]int64, canChange bool,
  20878. d *Decoder) (_ map[uint]int64, changed bool) {
  20879. dd, esep := d.d, d.hh.hasElemSeparators()
  20880. containerLen := dd.ReadMapStart()
  20881. if canChange && v == nil {
  20882. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  20883. v = make(map[uint]int64, xlen)
  20884. changed = true
  20885. }
  20886. if containerLen == 0 {
  20887. dd.ReadMapEnd()
  20888. return v, changed
  20889. }
  20890. var mk uint
  20891. var mv int64
  20892. hasLen := containerLen > 0
  20893. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20894. if esep {
  20895. dd.ReadMapElemKey()
  20896. }
  20897. mk = uint(dd.DecodeUint(uintBitsize))
  20898. if esep {
  20899. dd.ReadMapElemValue()
  20900. }
  20901. if dd.TryDecodeAsNil() {
  20902. if d.h.DeleteOnNilMapValue {
  20903. delete(v, mk)
  20904. } else {
  20905. v[mk] = 0
  20906. }
  20907. continue
  20908. }
  20909. mv = dd.DecodeInt(64)
  20910. if v != nil {
  20911. v[mk] = mv
  20912. }
  20913. }
  20914. dd.ReadMapEnd()
  20915. return v, changed
  20916. }
  20917. func (d *Decoder) fastpathDecMapUintFloat32R(f *codecFnInfo, rv reflect.Value) {
  20918. if rv.Kind() == reflect.Ptr {
  20919. vp := rv2i(rv).(*map[uint]float32)
  20920. if v, changed := fastpathTV.DecMapUintFloat32V(*vp, true, d); changed {
  20921. *vp = v
  20922. }
  20923. return
  20924. }
  20925. fastpathTV.DecMapUintFloat32V(rv2i(rv).(map[uint]float32), false, d)
  20926. }
  20927. func (f fastpathT) DecMapUintFloat32X(vp *map[uint]float32, d *Decoder) {
  20928. if v, changed := f.DecMapUintFloat32V(*vp, true, d); changed {
  20929. *vp = v
  20930. }
  20931. }
  20932. func (_ fastpathT) DecMapUintFloat32V(v map[uint]float32, canChange bool,
  20933. d *Decoder) (_ map[uint]float32, changed bool) {
  20934. dd, esep := d.d, d.hh.hasElemSeparators()
  20935. containerLen := dd.ReadMapStart()
  20936. if canChange && v == nil {
  20937. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  20938. v = make(map[uint]float32, xlen)
  20939. changed = true
  20940. }
  20941. if containerLen == 0 {
  20942. dd.ReadMapEnd()
  20943. return v, changed
  20944. }
  20945. var mk uint
  20946. var mv float32
  20947. hasLen := containerLen > 0
  20948. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20949. if esep {
  20950. dd.ReadMapElemKey()
  20951. }
  20952. mk = uint(dd.DecodeUint(uintBitsize))
  20953. if esep {
  20954. dd.ReadMapElemValue()
  20955. }
  20956. if dd.TryDecodeAsNil() {
  20957. if d.h.DeleteOnNilMapValue {
  20958. delete(v, mk)
  20959. } else {
  20960. v[mk] = 0
  20961. }
  20962. continue
  20963. }
  20964. mv = float32(dd.DecodeFloat(true))
  20965. if v != nil {
  20966. v[mk] = mv
  20967. }
  20968. }
  20969. dd.ReadMapEnd()
  20970. return v, changed
  20971. }
  20972. func (d *Decoder) fastpathDecMapUintFloat64R(f *codecFnInfo, rv reflect.Value) {
  20973. if rv.Kind() == reflect.Ptr {
  20974. vp := rv2i(rv).(*map[uint]float64)
  20975. if v, changed := fastpathTV.DecMapUintFloat64V(*vp, true, d); changed {
  20976. *vp = v
  20977. }
  20978. return
  20979. }
  20980. fastpathTV.DecMapUintFloat64V(rv2i(rv).(map[uint]float64), false, d)
  20981. }
  20982. func (f fastpathT) DecMapUintFloat64X(vp *map[uint]float64, d *Decoder) {
  20983. if v, changed := f.DecMapUintFloat64V(*vp, true, d); changed {
  20984. *vp = v
  20985. }
  20986. }
  20987. func (_ fastpathT) DecMapUintFloat64V(v map[uint]float64, canChange bool,
  20988. d *Decoder) (_ map[uint]float64, changed bool) {
  20989. dd, esep := d.d, d.hh.hasElemSeparators()
  20990. containerLen := dd.ReadMapStart()
  20991. if canChange && v == nil {
  20992. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  20993. v = make(map[uint]float64, xlen)
  20994. changed = true
  20995. }
  20996. if containerLen == 0 {
  20997. dd.ReadMapEnd()
  20998. return v, changed
  20999. }
  21000. var mk uint
  21001. var mv float64
  21002. hasLen := containerLen > 0
  21003. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21004. if esep {
  21005. dd.ReadMapElemKey()
  21006. }
  21007. mk = uint(dd.DecodeUint(uintBitsize))
  21008. if esep {
  21009. dd.ReadMapElemValue()
  21010. }
  21011. if dd.TryDecodeAsNil() {
  21012. if d.h.DeleteOnNilMapValue {
  21013. delete(v, mk)
  21014. } else {
  21015. v[mk] = 0
  21016. }
  21017. continue
  21018. }
  21019. mv = dd.DecodeFloat(false)
  21020. if v != nil {
  21021. v[mk] = mv
  21022. }
  21023. }
  21024. dd.ReadMapEnd()
  21025. return v, changed
  21026. }
  21027. func (d *Decoder) fastpathDecMapUintBoolR(f *codecFnInfo, rv reflect.Value) {
  21028. if rv.Kind() == reflect.Ptr {
  21029. vp := rv2i(rv).(*map[uint]bool)
  21030. if v, changed := fastpathTV.DecMapUintBoolV(*vp, true, d); changed {
  21031. *vp = v
  21032. }
  21033. return
  21034. }
  21035. fastpathTV.DecMapUintBoolV(rv2i(rv).(map[uint]bool), false, d)
  21036. }
  21037. func (f fastpathT) DecMapUintBoolX(vp *map[uint]bool, d *Decoder) {
  21038. if v, changed := f.DecMapUintBoolV(*vp, true, d); changed {
  21039. *vp = v
  21040. }
  21041. }
  21042. func (_ fastpathT) DecMapUintBoolV(v map[uint]bool, canChange bool,
  21043. d *Decoder) (_ map[uint]bool, changed bool) {
  21044. dd, esep := d.d, d.hh.hasElemSeparators()
  21045. containerLen := dd.ReadMapStart()
  21046. if canChange && v == nil {
  21047. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  21048. v = make(map[uint]bool, xlen)
  21049. changed = true
  21050. }
  21051. if containerLen == 0 {
  21052. dd.ReadMapEnd()
  21053. return v, changed
  21054. }
  21055. var mk uint
  21056. var mv bool
  21057. hasLen := containerLen > 0
  21058. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21059. if esep {
  21060. dd.ReadMapElemKey()
  21061. }
  21062. mk = uint(dd.DecodeUint(uintBitsize))
  21063. if esep {
  21064. dd.ReadMapElemValue()
  21065. }
  21066. if dd.TryDecodeAsNil() {
  21067. if d.h.DeleteOnNilMapValue {
  21068. delete(v, mk)
  21069. } else {
  21070. v[mk] = false
  21071. }
  21072. continue
  21073. }
  21074. mv = dd.DecodeBool()
  21075. if v != nil {
  21076. v[mk] = mv
  21077. }
  21078. }
  21079. dd.ReadMapEnd()
  21080. return v, changed
  21081. }
  21082. func (d *Decoder) fastpathDecMapUint8IntfR(f *codecFnInfo, rv reflect.Value) {
  21083. if rv.Kind() == reflect.Ptr {
  21084. vp := rv2i(rv).(*map[uint8]interface{})
  21085. if v, changed := fastpathTV.DecMapUint8IntfV(*vp, true, d); changed {
  21086. *vp = v
  21087. }
  21088. return
  21089. }
  21090. fastpathTV.DecMapUint8IntfV(rv2i(rv).(map[uint8]interface{}), false, d)
  21091. }
  21092. func (f fastpathT) DecMapUint8IntfX(vp *map[uint8]interface{}, d *Decoder) {
  21093. if v, changed := f.DecMapUint8IntfV(*vp, true, d); changed {
  21094. *vp = v
  21095. }
  21096. }
  21097. func (_ fastpathT) DecMapUint8IntfV(v map[uint8]interface{}, canChange bool,
  21098. d *Decoder) (_ map[uint8]interface{}, changed bool) {
  21099. dd, esep := d.d, d.hh.hasElemSeparators()
  21100. containerLen := dd.ReadMapStart()
  21101. if canChange && v == nil {
  21102. xlen := decInferLen(containerLen, d.h.MaxInitLen, 17)
  21103. v = make(map[uint8]interface{}, xlen)
  21104. changed = true
  21105. }
  21106. if containerLen == 0 {
  21107. dd.ReadMapEnd()
  21108. return v, changed
  21109. }
  21110. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  21111. var mk uint8
  21112. var mv interface{}
  21113. hasLen := containerLen > 0
  21114. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21115. if esep {
  21116. dd.ReadMapElemKey()
  21117. }
  21118. mk = uint8(dd.DecodeUint(8))
  21119. if esep {
  21120. dd.ReadMapElemValue()
  21121. }
  21122. if dd.TryDecodeAsNil() {
  21123. if d.h.DeleteOnNilMapValue {
  21124. delete(v, mk)
  21125. } else {
  21126. v[mk] = nil
  21127. }
  21128. continue
  21129. }
  21130. if mapGet {
  21131. mv = v[mk]
  21132. } else {
  21133. mv = nil
  21134. }
  21135. d.decode(&mv)
  21136. if v != nil {
  21137. v[mk] = mv
  21138. }
  21139. }
  21140. dd.ReadMapEnd()
  21141. return v, changed
  21142. }
  21143. func (d *Decoder) fastpathDecMapUint8StringR(f *codecFnInfo, rv reflect.Value) {
  21144. if rv.Kind() == reflect.Ptr {
  21145. vp := rv2i(rv).(*map[uint8]string)
  21146. if v, changed := fastpathTV.DecMapUint8StringV(*vp, true, d); changed {
  21147. *vp = v
  21148. }
  21149. return
  21150. }
  21151. fastpathTV.DecMapUint8StringV(rv2i(rv).(map[uint8]string), false, d)
  21152. }
  21153. func (f fastpathT) DecMapUint8StringX(vp *map[uint8]string, d *Decoder) {
  21154. if v, changed := f.DecMapUint8StringV(*vp, true, d); changed {
  21155. *vp = v
  21156. }
  21157. }
  21158. func (_ fastpathT) DecMapUint8StringV(v map[uint8]string, canChange bool,
  21159. d *Decoder) (_ map[uint8]string, changed bool) {
  21160. dd, esep := d.d, d.hh.hasElemSeparators()
  21161. containerLen := dd.ReadMapStart()
  21162. if canChange && v == nil {
  21163. xlen := decInferLen(containerLen, d.h.MaxInitLen, 17)
  21164. v = make(map[uint8]string, xlen)
  21165. changed = true
  21166. }
  21167. if containerLen == 0 {
  21168. dd.ReadMapEnd()
  21169. return v, changed
  21170. }
  21171. var mk uint8
  21172. var mv string
  21173. hasLen := containerLen > 0
  21174. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21175. if esep {
  21176. dd.ReadMapElemKey()
  21177. }
  21178. mk = uint8(dd.DecodeUint(8))
  21179. if esep {
  21180. dd.ReadMapElemValue()
  21181. }
  21182. if dd.TryDecodeAsNil() {
  21183. if d.h.DeleteOnNilMapValue {
  21184. delete(v, mk)
  21185. } else {
  21186. v[mk] = ""
  21187. }
  21188. continue
  21189. }
  21190. mv = dd.DecodeString()
  21191. if v != nil {
  21192. v[mk] = mv
  21193. }
  21194. }
  21195. dd.ReadMapEnd()
  21196. return v, changed
  21197. }
  21198. func (d *Decoder) fastpathDecMapUint8UintR(f *codecFnInfo, rv reflect.Value) {
  21199. if rv.Kind() == reflect.Ptr {
  21200. vp := rv2i(rv).(*map[uint8]uint)
  21201. if v, changed := fastpathTV.DecMapUint8UintV(*vp, true, d); changed {
  21202. *vp = v
  21203. }
  21204. return
  21205. }
  21206. fastpathTV.DecMapUint8UintV(rv2i(rv).(map[uint8]uint), false, d)
  21207. }
  21208. func (f fastpathT) DecMapUint8UintX(vp *map[uint8]uint, d *Decoder) {
  21209. if v, changed := f.DecMapUint8UintV(*vp, true, d); changed {
  21210. *vp = v
  21211. }
  21212. }
  21213. func (_ fastpathT) DecMapUint8UintV(v map[uint8]uint, canChange bool,
  21214. d *Decoder) (_ map[uint8]uint, changed bool) {
  21215. dd, esep := d.d, d.hh.hasElemSeparators()
  21216. containerLen := dd.ReadMapStart()
  21217. if canChange && v == nil {
  21218. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  21219. v = make(map[uint8]uint, xlen)
  21220. changed = true
  21221. }
  21222. if containerLen == 0 {
  21223. dd.ReadMapEnd()
  21224. return v, changed
  21225. }
  21226. var mk uint8
  21227. var mv uint
  21228. hasLen := containerLen > 0
  21229. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21230. if esep {
  21231. dd.ReadMapElemKey()
  21232. }
  21233. mk = uint8(dd.DecodeUint(8))
  21234. if esep {
  21235. dd.ReadMapElemValue()
  21236. }
  21237. if dd.TryDecodeAsNil() {
  21238. if d.h.DeleteOnNilMapValue {
  21239. delete(v, mk)
  21240. } else {
  21241. v[mk] = 0
  21242. }
  21243. continue
  21244. }
  21245. mv = uint(dd.DecodeUint(uintBitsize))
  21246. if v != nil {
  21247. v[mk] = mv
  21248. }
  21249. }
  21250. dd.ReadMapEnd()
  21251. return v, changed
  21252. }
  21253. func (d *Decoder) fastpathDecMapUint8Uint8R(f *codecFnInfo, rv reflect.Value) {
  21254. if rv.Kind() == reflect.Ptr {
  21255. vp := rv2i(rv).(*map[uint8]uint8)
  21256. if v, changed := fastpathTV.DecMapUint8Uint8V(*vp, true, d); changed {
  21257. *vp = v
  21258. }
  21259. return
  21260. }
  21261. fastpathTV.DecMapUint8Uint8V(rv2i(rv).(map[uint8]uint8), false, d)
  21262. }
  21263. func (f fastpathT) DecMapUint8Uint8X(vp *map[uint8]uint8, d *Decoder) {
  21264. if v, changed := f.DecMapUint8Uint8V(*vp, true, d); changed {
  21265. *vp = v
  21266. }
  21267. }
  21268. func (_ fastpathT) DecMapUint8Uint8V(v map[uint8]uint8, canChange bool,
  21269. d *Decoder) (_ map[uint8]uint8, changed bool) {
  21270. dd, esep := d.d, d.hh.hasElemSeparators()
  21271. containerLen := dd.ReadMapStart()
  21272. if canChange && v == nil {
  21273. xlen := decInferLen(containerLen, d.h.MaxInitLen, 2)
  21274. v = make(map[uint8]uint8, xlen)
  21275. changed = true
  21276. }
  21277. if containerLen == 0 {
  21278. dd.ReadMapEnd()
  21279. return v, changed
  21280. }
  21281. var mk uint8
  21282. var mv uint8
  21283. hasLen := containerLen > 0
  21284. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21285. if esep {
  21286. dd.ReadMapElemKey()
  21287. }
  21288. mk = uint8(dd.DecodeUint(8))
  21289. if esep {
  21290. dd.ReadMapElemValue()
  21291. }
  21292. if dd.TryDecodeAsNil() {
  21293. if d.h.DeleteOnNilMapValue {
  21294. delete(v, mk)
  21295. } else {
  21296. v[mk] = 0
  21297. }
  21298. continue
  21299. }
  21300. mv = uint8(dd.DecodeUint(8))
  21301. if v != nil {
  21302. v[mk] = mv
  21303. }
  21304. }
  21305. dd.ReadMapEnd()
  21306. return v, changed
  21307. }
  21308. func (d *Decoder) fastpathDecMapUint8Uint16R(f *codecFnInfo, rv reflect.Value) {
  21309. if rv.Kind() == reflect.Ptr {
  21310. vp := rv2i(rv).(*map[uint8]uint16)
  21311. if v, changed := fastpathTV.DecMapUint8Uint16V(*vp, true, d); changed {
  21312. *vp = v
  21313. }
  21314. return
  21315. }
  21316. fastpathTV.DecMapUint8Uint16V(rv2i(rv).(map[uint8]uint16), false, d)
  21317. }
  21318. func (f fastpathT) DecMapUint8Uint16X(vp *map[uint8]uint16, d *Decoder) {
  21319. if v, changed := f.DecMapUint8Uint16V(*vp, true, d); changed {
  21320. *vp = v
  21321. }
  21322. }
  21323. func (_ fastpathT) DecMapUint8Uint16V(v map[uint8]uint16, canChange bool,
  21324. d *Decoder) (_ map[uint8]uint16, changed bool) {
  21325. dd, esep := d.d, d.hh.hasElemSeparators()
  21326. containerLen := dd.ReadMapStart()
  21327. if canChange && v == nil {
  21328. xlen := decInferLen(containerLen, d.h.MaxInitLen, 3)
  21329. v = make(map[uint8]uint16, xlen)
  21330. changed = true
  21331. }
  21332. if containerLen == 0 {
  21333. dd.ReadMapEnd()
  21334. return v, changed
  21335. }
  21336. var mk uint8
  21337. var mv uint16
  21338. hasLen := containerLen > 0
  21339. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21340. if esep {
  21341. dd.ReadMapElemKey()
  21342. }
  21343. mk = uint8(dd.DecodeUint(8))
  21344. if esep {
  21345. dd.ReadMapElemValue()
  21346. }
  21347. if dd.TryDecodeAsNil() {
  21348. if d.h.DeleteOnNilMapValue {
  21349. delete(v, mk)
  21350. } else {
  21351. v[mk] = 0
  21352. }
  21353. continue
  21354. }
  21355. mv = uint16(dd.DecodeUint(16))
  21356. if v != nil {
  21357. v[mk] = mv
  21358. }
  21359. }
  21360. dd.ReadMapEnd()
  21361. return v, changed
  21362. }
  21363. func (d *Decoder) fastpathDecMapUint8Uint32R(f *codecFnInfo, rv reflect.Value) {
  21364. if rv.Kind() == reflect.Ptr {
  21365. vp := rv2i(rv).(*map[uint8]uint32)
  21366. if v, changed := fastpathTV.DecMapUint8Uint32V(*vp, true, d); changed {
  21367. *vp = v
  21368. }
  21369. return
  21370. }
  21371. fastpathTV.DecMapUint8Uint32V(rv2i(rv).(map[uint8]uint32), false, d)
  21372. }
  21373. func (f fastpathT) DecMapUint8Uint32X(vp *map[uint8]uint32, d *Decoder) {
  21374. if v, changed := f.DecMapUint8Uint32V(*vp, true, d); changed {
  21375. *vp = v
  21376. }
  21377. }
  21378. func (_ fastpathT) DecMapUint8Uint32V(v map[uint8]uint32, canChange bool,
  21379. d *Decoder) (_ map[uint8]uint32, changed bool) {
  21380. dd, esep := d.d, d.hh.hasElemSeparators()
  21381. containerLen := dd.ReadMapStart()
  21382. if canChange && v == nil {
  21383. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  21384. v = make(map[uint8]uint32, xlen)
  21385. changed = true
  21386. }
  21387. if containerLen == 0 {
  21388. dd.ReadMapEnd()
  21389. return v, changed
  21390. }
  21391. var mk uint8
  21392. var mv uint32
  21393. hasLen := containerLen > 0
  21394. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21395. if esep {
  21396. dd.ReadMapElemKey()
  21397. }
  21398. mk = uint8(dd.DecodeUint(8))
  21399. if esep {
  21400. dd.ReadMapElemValue()
  21401. }
  21402. if dd.TryDecodeAsNil() {
  21403. if d.h.DeleteOnNilMapValue {
  21404. delete(v, mk)
  21405. } else {
  21406. v[mk] = 0
  21407. }
  21408. continue
  21409. }
  21410. mv = uint32(dd.DecodeUint(32))
  21411. if v != nil {
  21412. v[mk] = mv
  21413. }
  21414. }
  21415. dd.ReadMapEnd()
  21416. return v, changed
  21417. }
  21418. func (d *Decoder) fastpathDecMapUint8Uint64R(f *codecFnInfo, rv reflect.Value) {
  21419. if rv.Kind() == reflect.Ptr {
  21420. vp := rv2i(rv).(*map[uint8]uint64)
  21421. if v, changed := fastpathTV.DecMapUint8Uint64V(*vp, true, d); changed {
  21422. *vp = v
  21423. }
  21424. return
  21425. }
  21426. fastpathTV.DecMapUint8Uint64V(rv2i(rv).(map[uint8]uint64), false, d)
  21427. }
  21428. func (f fastpathT) DecMapUint8Uint64X(vp *map[uint8]uint64, d *Decoder) {
  21429. if v, changed := f.DecMapUint8Uint64V(*vp, true, d); changed {
  21430. *vp = v
  21431. }
  21432. }
  21433. func (_ fastpathT) DecMapUint8Uint64V(v map[uint8]uint64, canChange bool,
  21434. d *Decoder) (_ map[uint8]uint64, changed bool) {
  21435. dd, esep := d.d, d.hh.hasElemSeparators()
  21436. containerLen := dd.ReadMapStart()
  21437. if canChange && v == nil {
  21438. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  21439. v = make(map[uint8]uint64, xlen)
  21440. changed = true
  21441. }
  21442. if containerLen == 0 {
  21443. dd.ReadMapEnd()
  21444. return v, changed
  21445. }
  21446. var mk uint8
  21447. var mv uint64
  21448. hasLen := containerLen > 0
  21449. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21450. if esep {
  21451. dd.ReadMapElemKey()
  21452. }
  21453. mk = uint8(dd.DecodeUint(8))
  21454. if esep {
  21455. dd.ReadMapElemValue()
  21456. }
  21457. if dd.TryDecodeAsNil() {
  21458. if d.h.DeleteOnNilMapValue {
  21459. delete(v, mk)
  21460. } else {
  21461. v[mk] = 0
  21462. }
  21463. continue
  21464. }
  21465. mv = dd.DecodeUint(64)
  21466. if v != nil {
  21467. v[mk] = mv
  21468. }
  21469. }
  21470. dd.ReadMapEnd()
  21471. return v, changed
  21472. }
  21473. func (d *Decoder) fastpathDecMapUint8UintptrR(f *codecFnInfo, rv reflect.Value) {
  21474. if rv.Kind() == reflect.Ptr {
  21475. vp := rv2i(rv).(*map[uint8]uintptr)
  21476. if v, changed := fastpathTV.DecMapUint8UintptrV(*vp, true, d); changed {
  21477. *vp = v
  21478. }
  21479. return
  21480. }
  21481. fastpathTV.DecMapUint8UintptrV(rv2i(rv).(map[uint8]uintptr), false, d)
  21482. }
  21483. func (f fastpathT) DecMapUint8UintptrX(vp *map[uint8]uintptr, d *Decoder) {
  21484. if v, changed := f.DecMapUint8UintptrV(*vp, true, d); changed {
  21485. *vp = v
  21486. }
  21487. }
  21488. func (_ fastpathT) DecMapUint8UintptrV(v map[uint8]uintptr, canChange bool,
  21489. d *Decoder) (_ map[uint8]uintptr, changed bool) {
  21490. dd, esep := d.d, d.hh.hasElemSeparators()
  21491. containerLen := dd.ReadMapStart()
  21492. if canChange && v == nil {
  21493. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  21494. v = make(map[uint8]uintptr, xlen)
  21495. changed = true
  21496. }
  21497. if containerLen == 0 {
  21498. dd.ReadMapEnd()
  21499. return v, changed
  21500. }
  21501. var mk uint8
  21502. var mv uintptr
  21503. hasLen := containerLen > 0
  21504. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21505. if esep {
  21506. dd.ReadMapElemKey()
  21507. }
  21508. mk = uint8(dd.DecodeUint(8))
  21509. if esep {
  21510. dd.ReadMapElemValue()
  21511. }
  21512. if dd.TryDecodeAsNil() {
  21513. if d.h.DeleteOnNilMapValue {
  21514. delete(v, mk)
  21515. } else {
  21516. v[mk] = 0
  21517. }
  21518. continue
  21519. }
  21520. mv = uintptr(dd.DecodeUint(uintBitsize))
  21521. if v != nil {
  21522. v[mk] = mv
  21523. }
  21524. }
  21525. dd.ReadMapEnd()
  21526. return v, changed
  21527. }
  21528. func (d *Decoder) fastpathDecMapUint8IntR(f *codecFnInfo, rv reflect.Value) {
  21529. if rv.Kind() == reflect.Ptr {
  21530. vp := rv2i(rv).(*map[uint8]int)
  21531. if v, changed := fastpathTV.DecMapUint8IntV(*vp, true, d); changed {
  21532. *vp = v
  21533. }
  21534. return
  21535. }
  21536. fastpathTV.DecMapUint8IntV(rv2i(rv).(map[uint8]int), false, d)
  21537. }
  21538. func (f fastpathT) DecMapUint8IntX(vp *map[uint8]int, d *Decoder) {
  21539. if v, changed := f.DecMapUint8IntV(*vp, true, d); changed {
  21540. *vp = v
  21541. }
  21542. }
  21543. func (_ fastpathT) DecMapUint8IntV(v map[uint8]int, canChange bool,
  21544. d *Decoder) (_ map[uint8]int, changed bool) {
  21545. dd, esep := d.d, d.hh.hasElemSeparators()
  21546. containerLen := dd.ReadMapStart()
  21547. if canChange && v == nil {
  21548. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  21549. v = make(map[uint8]int, xlen)
  21550. changed = true
  21551. }
  21552. if containerLen == 0 {
  21553. dd.ReadMapEnd()
  21554. return v, changed
  21555. }
  21556. var mk uint8
  21557. var mv int
  21558. hasLen := containerLen > 0
  21559. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21560. if esep {
  21561. dd.ReadMapElemKey()
  21562. }
  21563. mk = uint8(dd.DecodeUint(8))
  21564. if esep {
  21565. dd.ReadMapElemValue()
  21566. }
  21567. if dd.TryDecodeAsNil() {
  21568. if d.h.DeleteOnNilMapValue {
  21569. delete(v, mk)
  21570. } else {
  21571. v[mk] = 0
  21572. }
  21573. continue
  21574. }
  21575. mv = int(dd.DecodeInt(intBitsize))
  21576. if v != nil {
  21577. v[mk] = mv
  21578. }
  21579. }
  21580. dd.ReadMapEnd()
  21581. return v, changed
  21582. }
  21583. func (d *Decoder) fastpathDecMapUint8Int8R(f *codecFnInfo, rv reflect.Value) {
  21584. if rv.Kind() == reflect.Ptr {
  21585. vp := rv2i(rv).(*map[uint8]int8)
  21586. if v, changed := fastpathTV.DecMapUint8Int8V(*vp, true, d); changed {
  21587. *vp = v
  21588. }
  21589. return
  21590. }
  21591. fastpathTV.DecMapUint8Int8V(rv2i(rv).(map[uint8]int8), false, d)
  21592. }
  21593. func (f fastpathT) DecMapUint8Int8X(vp *map[uint8]int8, d *Decoder) {
  21594. if v, changed := f.DecMapUint8Int8V(*vp, true, d); changed {
  21595. *vp = v
  21596. }
  21597. }
  21598. func (_ fastpathT) DecMapUint8Int8V(v map[uint8]int8, canChange bool,
  21599. d *Decoder) (_ map[uint8]int8, changed bool) {
  21600. dd, esep := d.d, d.hh.hasElemSeparators()
  21601. containerLen := dd.ReadMapStart()
  21602. if canChange && v == nil {
  21603. xlen := decInferLen(containerLen, d.h.MaxInitLen, 2)
  21604. v = make(map[uint8]int8, xlen)
  21605. changed = true
  21606. }
  21607. if containerLen == 0 {
  21608. dd.ReadMapEnd()
  21609. return v, changed
  21610. }
  21611. var mk uint8
  21612. var mv int8
  21613. hasLen := containerLen > 0
  21614. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21615. if esep {
  21616. dd.ReadMapElemKey()
  21617. }
  21618. mk = uint8(dd.DecodeUint(8))
  21619. if esep {
  21620. dd.ReadMapElemValue()
  21621. }
  21622. if dd.TryDecodeAsNil() {
  21623. if d.h.DeleteOnNilMapValue {
  21624. delete(v, mk)
  21625. } else {
  21626. v[mk] = 0
  21627. }
  21628. continue
  21629. }
  21630. mv = int8(dd.DecodeInt(8))
  21631. if v != nil {
  21632. v[mk] = mv
  21633. }
  21634. }
  21635. dd.ReadMapEnd()
  21636. return v, changed
  21637. }
  21638. func (d *Decoder) fastpathDecMapUint8Int16R(f *codecFnInfo, rv reflect.Value) {
  21639. if rv.Kind() == reflect.Ptr {
  21640. vp := rv2i(rv).(*map[uint8]int16)
  21641. if v, changed := fastpathTV.DecMapUint8Int16V(*vp, true, d); changed {
  21642. *vp = v
  21643. }
  21644. return
  21645. }
  21646. fastpathTV.DecMapUint8Int16V(rv2i(rv).(map[uint8]int16), false, d)
  21647. }
  21648. func (f fastpathT) DecMapUint8Int16X(vp *map[uint8]int16, d *Decoder) {
  21649. if v, changed := f.DecMapUint8Int16V(*vp, true, d); changed {
  21650. *vp = v
  21651. }
  21652. }
  21653. func (_ fastpathT) DecMapUint8Int16V(v map[uint8]int16, canChange bool,
  21654. d *Decoder) (_ map[uint8]int16, changed bool) {
  21655. dd, esep := d.d, d.hh.hasElemSeparators()
  21656. containerLen := dd.ReadMapStart()
  21657. if canChange && v == nil {
  21658. xlen := decInferLen(containerLen, d.h.MaxInitLen, 3)
  21659. v = make(map[uint8]int16, xlen)
  21660. changed = true
  21661. }
  21662. if containerLen == 0 {
  21663. dd.ReadMapEnd()
  21664. return v, changed
  21665. }
  21666. var mk uint8
  21667. var mv int16
  21668. hasLen := containerLen > 0
  21669. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21670. if esep {
  21671. dd.ReadMapElemKey()
  21672. }
  21673. mk = uint8(dd.DecodeUint(8))
  21674. if esep {
  21675. dd.ReadMapElemValue()
  21676. }
  21677. if dd.TryDecodeAsNil() {
  21678. if d.h.DeleteOnNilMapValue {
  21679. delete(v, mk)
  21680. } else {
  21681. v[mk] = 0
  21682. }
  21683. continue
  21684. }
  21685. mv = int16(dd.DecodeInt(16))
  21686. if v != nil {
  21687. v[mk] = mv
  21688. }
  21689. }
  21690. dd.ReadMapEnd()
  21691. return v, changed
  21692. }
  21693. func (d *Decoder) fastpathDecMapUint8Int32R(f *codecFnInfo, rv reflect.Value) {
  21694. if rv.Kind() == reflect.Ptr {
  21695. vp := rv2i(rv).(*map[uint8]int32)
  21696. if v, changed := fastpathTV.DecMapUint8Int32V(*vp, true, d); changed {
  21697. *vp = v
  21698. }
  21699. return
  21700. }
  21701. fastpathTV.DecMapUint8Int32V(rv2i(rv).(map[uint8]int32), false, d)
  21702. }
  21703. func (f fastpathT) DecMapUint8Int32X(vp *map[uint8]int32, d *Decoder) {
  21704. if v, changed := f.DecMapUint8Int32V(*vp, true, d); changed {
  21705. *vp = v
  21706. }
  21707. }
  21708. func (_ fastpathT) DecMapUint8Int32V(v map[uint8]int32, canChange bool,
  21709. d *Decoder) (_ map[uint8]int32, changed bool) {
  21710. dd, esep := d.d, d.hh.hasElemSeparators()
  21711. containerLen := dd.ReadMapStart()
  21712. if canChange && v == nil {
  21713. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  21714. v = make(map[uint8]int32, xlen)
  21715. changed = true
  21716. }
  21717. if containerLen == 0 {
  21718. dd.ReadMapEnd()
  21719. return v, changed
  21720. }
  21721. var mk uint8
  21722. var mv int32
  21723. hasLen := containerLen > 0
  21724. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21725. if esep {
  21726. dd.ReadMapElemKey()
  21727. }
  21728. mk = uint8(dd.DecodeUint(8))
  21729. if esep {
  21730. dd.ReadMapElemValue()
  21731. }
  21732. if dd.TryDecodeAsNil() {
  21733. if d.h.DeleteOnNilMapValue {
  21734. delete(v, mk)
  21735. } else {
  21736. v[mk] = 0
  21737. }
  21738. continue
  21739. }
  21740. mv = int32(dd.DecodeInt(32))
  21741. if v != nil {
  21742. v[mk] = mv
  21743. }
  21744. }
  21745. dd.ReadMapEnd()
  21746. return v, changed
  21747. }
  21748. func (d *Decoder) fastpathDecMapUint8Int64R(f *codecFnInfo, rv reflect.Value) {
  21749. if rv.Kind() == reflect.Ptr {
  21750. vp := rv2i(rv).(*map[uint8]int64)
  21751. if v, changed := fastpathTV.DecMapUint8Int64V(*vp, true, d); changed {
  21752. *vp = v
  21753. }
  21754. return
  21755. }
  21756. fastpathTV.DecMapUint8Int64V(rv2i(rv).(map[uint8]int64), false, d)
  21757. }
  21758. func (f fastpathT) DecMapUint8Int64X(vp *map[uint8]int64, d *Decoder) {
  21759. if v, changed := f.DecMapUint8Int64V(*vp, true, d); changed {
  21760. *vp = v
  21761. }
  21762. }
  21763. func (_ fastpathT) DecMapUint8Int64V(v map[uint8]int64, canChange bool,
  21764. d *Decoder) (_ map[uint8]int64, changed bool) {
  21765. dd, esep := d.d, d.hh.hasElemSeparators()
  21766. containerLen := dd.ReadMapStart()
  21767. if canChange && v == nil {
  21768. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  21769. v = make(map[uint8]int64, xlen)
  21770. changed = true
  21771. }
  21772. if containerLen == 0 {
  21773. dd.ReadMapEnd()
  21774. return v, changed
  21775. }
  21776. var mk uint8
  21777. var mv int64
  21778. hasLen := containerLen > 0
  21779. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21780. if esep {
  21781. dd.ReadMapElemKey()
  21782. }
  21783. mk = uint8(dd.DecodeUint(8))
  21784. if esep {
  21785. dd.ReadMapElemValue()
  21786. }
  21787. if dd.TryDecodeAsNil() {
  21788. if d.h.DeleteOnNilMapValue {
  21789. delete(v, mk)
  21790. } else {
  21791. v[mk] = 0
  21792. }
  21793. continue
  21794. }
  21795. mv = dd.DecodeInt(64)
  21796. if v != nil {
  21797. v[mk] = mv
  21798. }
  21799. }
  21800. dd.ReadMapEnd()
  21801. return v, changed
  21802. }
  21803. func (d *Decoder) fastpathDecMapUint8Float32R(f *codecFnInfo, rv reflect.Value) {
  21804. if rv.Kind() == reflect.Ptr {
  21805. vp := rv2i(rv).(*map[uint8]float32)
  21806. if v, changed := fastpathTV.DecMapUint8Float32V(*vp, true, d); changed {
  21807. *vp = v
  21808. }
  21809. return
  21810. }
  21811. fastpathTV.DecMapUint8Float32V(rv2i(rv).(map[uint8]float32), false, d)
  21812. }
  21813. func (f fastpathT) DecMapUint8Float32X(vp *map[uint8]float32, d *Decoder) {
  21814. if v, changed := f.DecMapUint8Float32V(*vp, true, d); changed {
  21815. *vp = v
  21816. }
  21817. }
  21818. func (_ fastpathT) DecMapUint8Float32V(v map[uint8]float32, canChange bool,
  21819. d *Decoder) (_ map[uint8]float32, changed bool) {
  21820. dd, esep := d.d, d.hh.hasElemSeparators()
  21821. containerLen := dd.ReadMapStart()
  21822. if canChange && v == nil {
  21823. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  21824. v = make(map[uint8]float32, xlen)
  21825. changed = true
  21826. }
  21827. if containerLen == 0 {
  21828. dd.ReadMapEnd()
  21829. return v, changed
  21830. }
  21831. var mk uint8
  21832. var mv float32
  21833. hasLen := containerLen > 0
  21834. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21835. if esep {
  21836. dd.ReadMapElemKey()
  21837. }
  21838. mk = uint8(dd.DecodeUint(8))
  21839. if esep {
  21840. dd.ReadMapElemValue()
  21841. }
  21842. if dd.TryDecodeAsNil() {
  21843. if d.h.DeleteOnNilMapValue {
  21844. delete(v, mk)
  21845. } else {
  21846. v[mk] = 0
  21847. }
  21848. continue
  21849. }
  21850. mv = float32(dd.DecodeFloat(true))
  21851. if v != nil {
  21852. v[mk] = mv
  21853. }
  21854. }
  21855. dd.ReadMapEnd()
  21856. return v, changed
  21857. }
  21858. func (d *Decoder) fastpathDecMapUint8Float64R(f *codecFnInfo, rv reflect.Value) {
  21859. if rv.Kind() == reflect.Ptr {
  21860. vp := rv2i(rv).(*map[uint8]float64)
  21861. if v, changed := fastpathTV.DecMapUint8Float64V(*vp, true, d); changed {
  21862. *vp = v
  21863. }
  21864. return
  21865. }
  21866. fastpathTV.DecMapUint8Float64V(rv2i(rv).(map[uint8]float64), false, d)
  21867. }
  21868. func (f fastpathT) DecMapUint8Float64X(vp *map[uint8]float64, d *Decoder) {
  21869. if v, changed := f.DecMapUint8Float64V(*vp, true, d); changed {
  21870. *vp = v
  21871. }
  21872. }
  21873. func (_ fastpathT) DecMapUint8Float64V(v map[uint8]float64, canChange bool,
  21874. d *Decoder) (_ map[uint8]float64, changed bool) {
  21875. dd, esep := d.d, d.hh.hasElemSeparators()
  21876. containerLen := dd.ReadMapStart()
  21877. if canChange && v == nil {
  21878. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  21879. v = make(map[uint8]float64, xlen)
  21880. changed = true
  21881. }
  21882. if containerLen == 0 {
  21883. dd.ReadMapEnd()
  21884. return v, changed
  21885. }
  21886. var mk uint8
  21887. var mv float64
  21888. hasLen := containerLen > 0
  21889. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21890. if esep {
  21891. dd.ReadMapElemKey()
  21892. }
  21893. mk = uint8(dd.DecodeUint(8))
  21894. if esep {
  21895. dd.ReadMapElemValue()
  21896. }
  21897. if dd.TryDecodeAsNil() {
  21898. if d.h.DeleteOnNilMapValue {
  21899. delete(v, mk)
  21900. } else {
  21901. v[mk] = 0
  21902. }
  21903. continue
  21904. }
  21905. mv = dd.DecodeFloat(false)
  21906. if v != nil {
  21907. v[mk] = mv
  21908. }
  21909. }
  21910. dd.ReadMapEnd()
  21911. return v, changed
  21912. }
  21913. func (d *Decoder) fastpathDecMapUint8BoolR(f *codecFnInfo, rv reflect.Value) {
  21914. if rv.Kind() == reflect.Ptr {
  21915. vp := rv2i(rv).(*map[uint8]bool)
  21916. if v, changed := fastpathTV.DecMapUint8BoolV(*vp, true, d); changed {
  21917. *vp = v
  21918. }
  21919. return
  21920. }
  21921. fastpathTV.DecMapUint8BoolV(rv2i(rv).(map[uint8]bool), false, d)
  21922. }
  21923. func (f fastpathT) DecMapUint8BoolX(vp *map[uint8]bool, d *Decoder) {
  21924. if v, changed := f.DecMapUint8BoolV(*vp, true, d); changed {
  21925. *vp = v
  21926. }
  21927. }
  21928. func (_ fastpathT) DecMapUint8BoolV(v map[uint8]bool, canChange bool,
  21929. d *Decoder) (_ map[uint8]bool, changed bool) {
  21930. dd, esep := d.d, d.hh.hasElemSeparators()
  21931. containerLen := dd.ReadMapStart()
  21932. if canChange && v == nil {
  21933. xlen := decInferLen(containerLen, d.h.MaxInitLen, 2)
  21934. v = make(map[uint8]bool, xlen)
  21935. changed = true
  21936. }
  21937. if containerLen == 0 {
  21938. dd.ReadMapEnd()
  21939. return v, changed
  21940. }
  21941. var mk uint8
  21942. var mv bool
  21943. hasLen := containerLen > 0
  21944. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21945. if esep {
  21946. dd.ReadMapElemKey()
  21947. }
  21948. mk = uint8(dd.DecodeUint(8))
  21949. if esep {
  21950. dd.ReadMapElemValue()
  21951. }
  21952. if dd.TryDecodeAsNil() {
  21953. if d.h.DeleteOnNilMapValue {
  21954. delete(v, mk)
  21955. } else {
  21956. v[mk] = false
  21957. }
  21958. continue
  21959. }
  21960. mv = dd.DecodeBool()
  21961. if v != nil {
  21962. v[mk] = mv
  21963. }
  21964. }
  21965. dd.ReadMapEnd()
  21966. return v, changed
  21967. }
  21968. func (d *Decoder) fastpathDecMapUint16IntfR(f *codecFnInfo, rv reflect.Value) {
  21969. if rv.Kind() == reflect.Ptr {
  21970. vp := rv2i(rv).(*map[uint16]interface{})
  21971. if v, changed := fastpathTV.DecMapUint16IntfV(*vp, true, d); changed {
  21972. *vp = v
  21973. }
  21974. return
  21975. }
  21976. fastpathTV.DecMapUint16IntfV(rv2i(rv).(map[uint16]interface{}), false, d)
  21977. }
  21978. func (f fastpathT) DecMapUint16IntfX(vp *map[uint16]interface{}, d *Decoder) {
  21979. if v, changed := f.DecMapUint16IntfV(*vp, true, d); changed {
  21980. *vp = v
  21981. }
  21982. }
  21983. func (_ fastpathT) DecMapUint16IntfV(v map[uint16]interface{}, canChange bool,
  21984. d *Decoder) (_ map[uint16]interface{}, changed bool) {
  21985. dd, esep := d.d, d.hh.hasElemSeparators()
  21986. containerLen := dd.ReadMapStart()
  21987. if canChange && v == nil {
  21988. xlen := decInferLen(containerLen, d.h.MaxInitLen, 18)
  21989. v = make(map[uint16]interface{}, xlen)
  21990. changed = true
  21991. }
  21992. if containerLen == 0 {
  21993. dd.ReadMapEnd()
  21994. return v, changed
  21995. }
  21996. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  21997. var mk uint16
  21998. var mv interface{}
  21999. hasLen := containerLen > 0
  22000. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22001. if esep {
  22002. dd.ReadMapElemKey()
  22003. }
  22004. mk = uint16(dd.DecodeUint(16))
  22005. if esep {
  22006. dd.ReadMapElemValue()
  22007. }
  22008. if dd.TryDecodeAsNil() {
  22009. if d.h.DeleteOnNilMapValue {
  22010. delete(v, mk)
  22011. } else {
  22012. v[mk] = nil
  22013. }
  22014. continue
  22015. }
  22016. if mapGet {
  22017. mv = v[mk]
  22018. } else {
  22019. mv = nil
  22020. }
  22021. d.decode(&mv)
  22022. if v != nil {
  22023. v[mk] = mv
  22024. }
  22025. }
  22026. dd.ReadMapEnd()
  22027. return v, changed
  22028. }
  22029. func (d *Decoder) fastpathDecMapUint16StringR(f *codecFnInfo, rv reflect.Value) {
  22030. if rv.Kind() == reflect.Ptr {
  22031. vp := rv2i(rv).(*map[uint16]string)
  22032. if v, changed := fastpathTV.DecMapUint16StringV(*vp, true, d); changed {
  22033. *vp = v
  22034. }
  22035. return
  22036. }
  22037. fastpathTV.DecMapUint16StringV(rv2i(rv).(map[uint16]string), false, d)
  22038. }
  22039. func (f fastpathT) DecMapUint16StringX(vp *map[uint16]string, d *Decoder) {
  22040. if v, changed := f.DecMapUint16StringV(*vp, true, d); changed {
  22041. *vp = v
  22042. }
  22043. }
  22044. func (_ fastpathT) DecMapUint16StringV(v map[uint16]string, canChange bool,
  22045. d *Decoder) (_ map[uint16]string, changed bool) {
  22046. dd, esep := d.d, d.hh.hasElemSeparators()
  22047. containerLen := dd.ReadMapStart()
  22048. if canChange && v == nil {
  22049. xlen := decInferLen(containerLen, d.h.MaxInitLen, 18)
  22050. v = make(map[uint16]string, xlen)
  22051. changed = true
  22052. }
  22053. if containerLen == 0 {
  22054. dd.ReadMapEnd()
  22055. return v, changed
  22056. }
  22057. var mk uint16
  22058. var mv string
  22059. hasLen := containerLen > 0
  22060. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22061. if esep {
  22062. dd.ReadMapElemKey()
  22063. }
  22064. mk = uint16(dd.DecodeUint(16))
  22065. if esep {
  22066. dd.ReadMapElemValue()
  22067. }
  22068. if dd.TryDecodeAsNil() {
  22069. if d.h.DeleteOnNilMapValue {
  22070. delete(v, mk)
  22071. } else {
  22072. v[mk] = ""
  22073. }
  22074. continue
  22075. }
  22076. mv = dd.DecodeString()
  22077. if v != nil {
  22078. v[mk] = mv
  22079. }
  22080. }
  22081. dd.ReadMapEnd()
  22082. return v, changed
  22083. }
  22084. func (d *Decoder) fastpathDecMapUint16UintR(f *codecFnInfo, rv reflect.Value) {
  22085. if rv.Kind() == reflect.Ptr {
  22086. vp := rv2i(rv).(*map[uint16]uint)
  22087. if v, changed := fastpathTV.DecMapUint16UintV(*vp, true, d); changed {
  22088. *vp = v
  22089. }
  22090. return
  22091. }
  22092. fastpathTV.DecMapUint16UintV(rv2i(rv).(map[uint16]uint), false, d)
  22093. }
  22094. func (f fastpathT) DecMapUint16UintX(vp *map[uint16]uint, d *Decoder) {
  22095. if v, changed := f.DecMapUint16UintV(*vp, true, d); changed {
  22096. *vp = v
  22097. }
  22098. }
  22099. func (_ fastpathT) DecMapUint16UintV(v map[uint16]uint, canChange bool,
  22100. d *Decoder) (_ map[uint16]uint, changed bool) {
  22101. dd, esep := d.d, d.hh.hasElemSeparators()
  22102. containerLen := dd.ReadMapStart()
  22103. if canChange && v == nil {
  22104. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  22105. v = make(map[uint16]uint, xlen)
  22106. changed = true
  22107. }
  22108. if containerLen == 0 {
  22109. dd.ReadMapEnd()
  22110. return v, changed
  22111. }
  22112. var mk uint16
  22113. var mv uint
  22114. hasLen := containerLen > 0
  22115. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22116. if esep {
  22117. dd.ReadMapElemKey()
  22118. }
  22119. mk = uint16(dd.DecodeUint(16))
  22120. if esep {
  22121. dd.ReadMapElemValue()
  22122. }
  22123. if dd.TryDecodeAsNil() {
  22124. if d.h.DeleteOnNilMapValue {
  22125. delete(v, mk)
  22126. } else {
  22127. v[mk] = 0
  22128. }
  22129. continue
  22130. }
  22131. mv = uint(dd.DecodeUint(uintBitsize))
  22132. if v != nil {
  22133. v[mk] = mv
  22134. }
  22135. }
  22136. dd.ReadMapEnd()
  22137. return v, changed
  22138. }
  22139. func (d *Decoder) fastpathDecMapUint16Uint8R(f *codecFnInfo, rv reflect.Value) {
  22140. if rv.Kind() == reflect.Ptr {
  22141. vp := rv2i(rv).(*map[uint16]uint8)
  22142. if v, changed := fastpathTV.DecMapUint16Uint8V(*vp, true, d); changed {
  22143. *vp = v
  22144. }
  22145. return
  22146. }
  22147. fastpathTV.DecMapUint16Uint8V(rv2i(rv).(map[uint16]uint8), false, d)
  22148. }
  22149. func (f fastpathT) DecMapUint16Uint8X(vp *map[uint16]uint8, d *Decoder) {
  22150. if v, changed := f.DecMapUint16Uint8V(*vp, true, d); changed {
  22151. *vp = v
  22152. }
  22153. }
  22154. func (_ fastpathT) DecMapUint16Uint8V(v map[uint16]uint8, canChange bool,
  22155. d *Decoder) (_ map[uint16]uint8, changed bool) {
  22156. dd, esep := d.d, d.hh.hasElemSeparators()
  22157. containerLen := dd.ReadMapStart()
  22158. if canChange && v == nil {
  22159. xlen := decInferLen(containerLen, d.h.MaxInitLen, 3)
  22160. v = make(map[uint16]uint8, xlen)
  22161. changed = true
  22162. }
  22163. if containerLen == 0 {
  22164. dd.ReadMapEnd()
  22165. return v, changed
  22166. }
  22167. var mk uint16
  22168. var mv uint8
  22169. hasLen := containerLen > 0
  22170. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22171. if esep {
  22172. dd.ReadMapElemKey()
  22173. }
  22174. mk = uint16(dd.DecodeUint(16))
  22175. if esep {
  22176. dd.ReadMapElemValue()
  22177. }
  22178. if dd.TryDecodeAsNil() {
  22179. if d.h.DeleteOnNilMapValue {
  22180. delete(v, mk)
  22181. } else {
  22182. v[mk] = 0
  22183. }
  22184. continue
  22185. }
  22186. mv = uint8(dd.DecodeUint(8))
  22187. if v != nil {
  22188. v[mk] = mv
  22189. }
  22190. }
  22191. dd.ReadMapEnd()
  22192. return v, changed
  22193. }
  22194. func (d *Decoder) fastpathDecMapUint16Uint16R(f *codecFnInfo, rv reflect.Value) {
  22195. if rv.Kind() == reflect.Ptr {
  22196. vp := rv2i(rv).(*map[uint16]uint16)
  22197. if v, changed := fastpathTV.DecMapUint16Uint16V(*vp, true, d); changed {
  22198. *vp = v
  22199. }
  22200. return
  22201. }
  22202. fastpathTV.DecMapUint16Uint16V(rv2i(rv).(map[uint16]uint16), false, d)
  22203. }
  22204. func (f fastpathT) DecMapUint16Uint16X(vp *map[uint16]uint16, d *Decoder) {
  22205. if v, changed := f.DecMapUint16Uint16V(*vp, true, d); changed {
  22206. *vp = v
  22207. }
  22208. }
  22209. func (_ fastpathT) DecMapUint16Uint16V(v map[uint16]uint16, canChange bool,
  22210. d *Decoder) (_ map[uint16]uint16, changed bool) {
  22211. dd, esep := d.d, d.hh.hasElemSeparators()
  22212. containerLen := dd.ReadMapStart()
  22213. if canChange && v == nil {
  22214. xlen := decInferLen(containerLen, d.h.MaxInitLen, 4)
  22215. v = make(map[uint16]uint16, xlen)
  22216. changed = true
  22217. }
  22218. if containerLen == 0 {
  22219. dd.ReadMapEnd()
  22220. return v, changed
  22221. }
  22222. var mk uint16
  22223. var mv uint16
  22224. hasLen := containerLen > 0
  22225. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22226. if esep {
  22227. dd.ReadMapElemKey()
  22228. }
  22229. mk = uint16(dd.DecodeUint(16))
  22230. if esep {
  22231. dd.ReadMapElemValue()
  22232. }
  22233. if dd.TryDecodeAsNil() {
  22234. if d.h.DeleteOnNilMapValue {
  22235. delete(v, mk)
  22236. } else {
  22237. v[mk] = 0
  22238. }
  22239. continue
  22240. }
  22241. mv = uint16(dd.DecodeUint(16))
  22242. if v != nil {
  22243. v[mk] = mv
  22244. }
  22245. }
  22246. dd.ReadMapEnd()
  22247. return v, changed
  22248. }
  22249. func (d *Decoder) fastpathDecMapUint16Uint32R(f *codecFnInfo, rv reflect.Value) {
  22250. if rv.Kind() == reflect.Ptr {
  22251. vp := rv2i(rv).(*map[uint16]uint32)
  22252. if v, changed := fastpathTV.DecMapUint16Uint32V(*vp, true, d); changed {
  22253. *vp = v
  22254. }
  22255. return
  22256. }
  22257. fastpathTV.DecMapUint16Uint32V(rv2i(rv).(map[uint16]uint32), false, d)
  22258. }
  22259. func (f fastpathT) DecMapUint16Uint32X(vp *map[uint16]uint32, d *Decoder) {
  22260. if v, changed := f.DecMapUint16Uint32V(*vp, true, d); changed {
  22261. *vp = v
  22262. }
  22263. }
  22264. func (_ fastpathT) DecMapUint16Uint32V(v map[uint16]uint32, canChange bool,
  22265. d *Decoder) (_ map[uint16]uint32, changed bool) {
  22266. dd, esep := d.d, d.hh.hasElemSeparators()
  22267. containerLen := dd.ReadMapStart()
  22268. if canChange && v == nil {
  22269. xlen := decInferLen(containerLen, d.h.MaxInitLen, 6)
  22270. v = make(map[uint16]uint32, xlen)
  22271. changed = true
  22272. }
  22273. if containerLen == 0 {
  22274. dd.ReadMapEnd()
  22275. return v, changed
  22276. }
  22277. var mk uint16
  22278. var mv uint32
  22279. hasLen := containerLen > 0
  22280. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22281. if esep {
  22282. dd.ReadMapElemKey()
  22283. }
  22284. mk = uint16(dd.DecodeUint(16))
  22285. if esep {
  22286. dd.ReadMapElemValue()
  22287. }
  22288. if dd.TryDecodeAsNil() {
  22289. if d.h.DeleteOnNilMapValue {
  22290. delete(v, mk)
  22291. } else {
  22292. v[mk] = 0
  22293. }
  22294. continue
  22295. }
  22296. mv = uint32(dd.DecodeUint(32))
  22297. if v != nil {
  22298. v[mk] = mv
  22299. }
  22300. }
  22301. dd.ReadMapEnd()
  22302. return v, changed
  22303. }
  22304. func (d *Decoder) fastpathDecMapUint16Uint64R(f *codecFnInfo, rv reflect.Value) {
  22305. if rv.Kind() == reflect.Ptr {
  22306. vp := rv2i(rv).(*map[uint16]uint64)
  22307. if v, changed := fastpathTV.DecMapUint16Uint64V(*vp, true, d); changed {
  22308. *vp = v
  22309. }
  22310. return
  22311. }
  22312. fastpathTV.DecMapUint16Uint64V(rv2i(rv).(map[uint16]uint64), false, d)
  22313. }
  22314. func (f fastpathT) DecMapUint16Uint64X(vp *map[uint16]uint64, d *Decoder) {
  22315. if v, changed := f.DecMapUint16Uint64V(*vp, true, d); changed {
  22316. *vp = v
  22317. }
  22318. }
  22319. func (_ fastpathT) DecMapUint16Uint64V(v map[uint16]uint64, canChange bool,
  22320. d *Decoder) (_ map[uint16]uint64, changed bool) {
  22321. dd, esep := d.d, d.hh.hasElemSeparators()
  22322. containerLen := dd.ReadMapStart()
  22323. if canChange && v == nil {
  22324. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  22325. v = make(map[uint16]uint64, xlen)
  22326. changed = true
  22327. }
  22328. if containerLen == 0 {
  22329. dd.ReadMapEnd()
  22330. return v, changed
  22331. }
  22332. var mk uint16
  22333. var mv uint64
  22334. hasLen := containerLen > 0
  22335. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22336. if esep {
  22337. dd.ReadMapElemKey()
  22338. }
  22339. mk = uint16(dd.DecodeUint(16))
  22340. if esep {
  22341. dd.ReadMapElemValue()
  22342. }
  22343. if dd.TryDecodeAsNil() {
  22344. if d.h.DeleteOnNilMapValue {
  22345. delete(v, mk)
  22346. } else {
  22347. v[mk] = 0
  22348. }
  22349. continue
  22350. }
  22351. mv = dd.DecodeUint(64)
  22352. if v != nil {
  22353. v[mk] = mv
  22354. }
  22355. }
  22356. dd.ReadMapEnd()
  22357. return v, changed
  22358. }
  22359. func (d *Decoder) fastpathDecMapUint16UintptrR(f *codecFnInfo, rv reflect.Value) {
  22360. if rv.Kind() == reflect.Ptr {
  22361. vp := rv2i(rv).(*map[uint16]uintptr)
  22362. if v, changed := fastpathTV.DecMapUint16UintptrV(*vp, true, d); changed {
  22363. *vp = v
  22364. }
  22365. return
  22366. }
  22367. fastpathTV.DecMapUint16UintptrV(rv2i(rv).(map[uint16]uintptr), false, d)
  22368. }
  22369. func (f fastpathT) DecMapUint16UintptrX(vp *map[uint16]uintptr, d *Decoder) {
  22370. if v, changed := f.DecMapUint16UintptrV(*vp, true, d); changed {
  22371. *vp = v
  22372. }
  22373. }
  22374. func (_ fastpathT) DecMapUint16UintptrV(v map[uint16]uintptr, canChange bool,
  22375. d *Decoder) (_ map[uint16]uintptr, changed bool) {
  22376. dd, esep := d.d, d.hh.hasElemSeparators()
  22377. containerLen := dd.ReadMapStart()
  22378. if canChange && v == nil {
  22379. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  22380. v = make(map[uint16]uintptr, xlen)
  22381. changed = true
  22382. }
  22383. if containerLen == 0 {
  22384. dd.ReadMapEnd()
  22385. return v, changed
  22386. }
  22387. var mk uint16
  22388. var mv uintptr
  22389. hasLen := containerLen > 0
  22390. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22391. if esep {
  22392. dd.ReadMapElemKey()
  22393. }
  22394. mk = uint16(dd.DecodeUint(16))
  22395. if esep {
  22396. dd.ReadMapElemValue()
  22397. }
  22398. if dd.TryDecodeAsNil() {
  22399. if d.h.DeleteOnNilMapValue {
  22400. delete(v, mk)
  22401. } else {
  22402. v[mk] = 0
  22403. }
  22404. continue
  22405. }
  22406. mv = uintptr(dd.DecodeUint(uintBitsize))
  22407. if v != nil {
  22408. v[mk] = mv
  22409. }
  22410. }
  22411. dd.ReadMapEnd()
  22412. return v, changed
  22413. }
  22414. func (d *Decoder) fastpathDecMapUint16IntR(f *codecFnInfo, rv reflect.Value) {
  22415. if rv.Kind() == reflect.Ptr {
  22416. vp := rv2i(rv).(*map[uint16]int)
  22417. if v, changed := fastpathTV.DecMapUint16IntV(*vp, true, d); changed {
  22418. *vp = v
  22419. }
  22420. return
  22421. }
  22422. fastpathTV.DecMapUint16IntV(rv2i(rv).(map[uint16]int), false, d)
  22423. }
  22424. func (f fastpathT) DecMapUint16IntX(vp *map[uint16]int, d *Decoder) {
  22425. if v, changed := f.DecMapUint16IntV(*vp, true, d); changed {
  22426. *vp = v
  22427. }
  22428. }
  22429. func (_ fastpathT) DecMapUint16IntV(v map[uint16]int, canChange bool,
  22430. d *Decoder) (_ map[uint16]int, changed bool) {
  22431. dd, esep := d.d, d.hh.hasElemSeparators()
  22432. containerLen := dd.ReadMapStart()
  22433. if canChange && v == nil {
  22434. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  22435. v = make(map[uint16]int, xlen)
  22436. changed = true
  22437. }
  22438. if containerLen == 0 {
  22439. dd.ReadMapEnd()
  22440. return v, changed
  22441. }
  22442. var mk uint16
  22443. var mv int
  22444. hasLen := containerLen > 0
  22445. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22446. if esep {
  22447. dd.ReadMapElemKey()
  22448. }
  22449. mk = uint16(dd.DecodeUint(16))
  22450. if esep {
  22451. dd.ReadMapElemValue()
  22452. }
  22453. if dd.TryDecodeAsNil() {
  22454. if d.h.DeleteOnNilMapValue {
  22455. delete(v, mk)
  22456. } else {
  22457. v[mk] = 0
  22458. }
  22459. continue
  22460. }
  22461. mv = int(dd.DecodeInt(intBitsize))
  22462. if v != nil {
  22463. v[mk] = mv
  22464. }
  22465. }
  22466. dd.ReadMapEnd()
  22467. return v, changed
  22468. }
  22469. func (d *Decoder) fastpathDecMapUint16Int8R(f *codecFnInfo, rv reflect.Value) {
  22470. if rv.Kind() == reflect.Ptr {
  22471. vp := rv2i(rv).(*map[uint16]int8)
  22472. if v, changed := fastpathTV.DecMapUint16Int8V(*vp, true, d); changed {
  22473. *vp = v
  22474. }
  22475. return
  22476. }
  22477. fastpathTV.DecMapUint16Int8V(rv2i(rv).(map[uint16]int8), false, d)
  22478. }
  22479. func (f fastpathT) DecMapUint16Int8X(vp *map[uint16]int8, d *Decoder) {
  22480. if v, changed := f.DecMapUint16Int8V(*vp, true, d); changed {
  22481. *vp = v
  22482. }
  22483. }
  22484. func (_ fastpathT) DecMapUint16Int8V(v map[uint16]int8, canChange bool,
  22485. d *Decoder) (_ map[uint16]int8, changed bool) {
  22486. dd, esep := d.d, d.hh.hasElemSeparators()
  22487. containerLen := dd.ReadMapStart()
  22488. if canChange && v == nil {
  22489. xlen := decInferLen(containerLen, d.h.MaxInitLen, 3)
  22490. v = make(map[uint16]int8, xlen)
  22491. changed = true
  22492. }
  22493. if containerLen == 0 {
  22494. dd.ReadMapEnd()
  22495. return v, changed
  22496. }
  22497. var mk uint16
  22498. var mv int8
  22499. hasLen := containerLen > 0
  22500. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22501. if esep {
  22502. dd.ReadMapElemKey()
  22503. }
  22504. mk = uint16(dd.DecodeUint(16))
  22505. if esep {
  22506. dd.ReadMapElemValue()
  22507. }
  22508. if dd.TryDecodeAsNil() {
  22509. if d.h.DeleteOnNilMapValue {
  22510. delete(v, mk)
  22511. } else {
  22512. v[mk] = 0
  22513. }
  22514. continue
  22515. }
  22516. mv = int8(dd.DecodeInt(8))
  22517. if v != nil {
  22518. v[mk] = mv
  22519. }
  22520. }
  22521. dd.ReadMapEnd()
  22522. return v, changed
  22523. }
  22524. func (d *Decoder) fastpathDecMapUint16Int16R(f *codecFnInfo, rv reflect.Value) {
  22525. if rv.Kind() == reflect.Ptr {
  22526. vp := rv2i(rv).(*map[uint16]int16)
  22527. if v, changed := fastpathTV.DecMapUint16Int16V(*vp, true, d); changed {
  22528. *vp = v
  22529. }
  22530. return
  22531. }
  22532. fastpathTV.DecMapUint16Int16V(rv2i(rv).(map[uint16]int16), false, d)
  22533. }
  22534. func (f fastpathT) DecMapUint16Int16X(vp *map[uint16]int16, d *Decoder) {
  22535. if v, changed := f.DecMapUint16Int16V(*vp, true, d); changed {
  22536. *vp = v
  22537. }
  22538. }
  22539. func (_ fastpathT) DecMapUint16Int16V(v map[uint16]int16, canChange bool,
  22540. d *Decoder) (_ map[uint16]int16, changed bool) {
  22541. dd, esep := d.d, d.hh.hasElemSeparators()
  22542. containerLen := dd.ReadMapStart()
  22543. if canChange && v == nil {
  22544. xlen := decInferLen(containerLen, d.h.MaxInitLen, 4)
  22545. v = make(map[uint16]int16, xlen)
  22546. changed = true
  22547. }
  22548. if containerLen == 0 {
  22549. dd.ReadMapEnd()
  22550. return v, changed
  22551. }
  22552. var mk uint16
  22553. var mv int16
  22554. hasLen := containerLen > 0
  22555. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22556. if esep {
  22557. dd.ReadMapElemKey()
  22558. }
  22559. mk = uint16(dd.DecodeUint(16))
  22560. if esep {
  22561. dd.ReadMapElemValue()
  22562. }
  22563. if dd.TryDecodeAsNil() {
  22564. if d.h.DeleteOnNilMapValue {
  22565. delete(v, mk)
  22566. } else {
  22567. v[mk] = 0
  22568. }
  22569. continue
  22570. }
  22571. mv = int16(dd.DecodeInt(16))
  22572. if v != nil {
  22573. v[mk] = mv
  22574. }
  22575. }
  22576. dd.ReadMapEnd()
  22577. return v, changed
  22578. }
  22579. func (d *Decoder) fastpathDecMapUint16Int32R(f *codecFnInfo, rv reflect.Value) {
  22580. if rv.Kind() == reflect.Ptr {
  22581. vp := rv2i(rv).(*map[uint16]int32)
  22582. if v, changed := fastpathTV.DecMapUint16Int32V(*vp, true, d); changed {
  22583. *vp = v
  22584. }
  22585. return
  22586. }
  22587. fastpathTV.DecMapUint16Int32V(rv2i(rv).(map[uint16]int32), false, d)
  22588. }
  22589. func (f fastpathT) DecMapUint16Int32X(vp *map[uint16]int32, d *Decoder) {
  22590. if v, changed := f.DecMapUint16Int32V(*vp, true, d); changed {
  22591. *vp = v
  22592. }
  22593. }
  22594. func (_ fastpathT) DecMapUint16Int32V(v map[uint16]int32, canChange bool,
  22595. d *Decoder) (_ map[uint16]int32, changed bool) {
  22596. dd, esep := d.d, d.hh.hasElemSeparators()
  22597. containerLen := dd.ReadMapStart()
  22598. if canChange && v == nil {
  22599. xlen := decInferLen(containerLen, d.h.MaxInitLen, 6)
  22600. v = make(map[uint16]int32, xlen)
  22601. changed = true
  22602. }
  22603. if containerLen == 0 {
  22604. dd.ReadMapEnd()
  22605. return v, changed
  22606. }
  22607. var mk uint16
  22608. var mv int32
  22609. hasLen := containerLen > 0
  22610. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22611. if esep {
  22612. dd.ReadMapElemKey()
  22613. }
  22614. mk = uint16(dd.DecodeUint(16))
  22615. if esep {
  22616. dd.ReadMapElemValue()
  22617. }
  22618. if dd.TryDecodeAsNil() {
  22619. if d.h.DeleteOnNilMapValue {
  22620. delete(v, mk)
  22621. } else {
  22622. v[mk] = 0
  22623. }
  22624. continue
  22625. }
  22626. mv = int32(dd.DecodeInt(32))
  22627. if v != nil {
  22628. v[mk] = mv
  22629. }
  22630. }
  22631. dd.ReadMapEnd()
  22632. return v, changed
  22633. }
  22634. func (d *Decoder) fastpathDecMapUint16Int64R(f *codecFnInfo, rv reflect.Value) {
  22635. if rv.Kind() == reflect.Ptr {
  22636. vp := rv2i(rv).(*map[uint16]int64)
  22637. if v, changed := fastpathTV.DecMapUint16Int64V(*vp, true, d); changed {
  22638. *vp = v
  22639. }
  22640. return
  22641. }
  22642. fastpathTV.DecMapUint16Int64V(rv2i(rv).(map[uint16]int64), false, d)
  22643. }
  22644. func (f fastpathT) DecMapUint16Int64X(vp *map[uint16]int64, d *Decoder) {
  22645. if v, changed := f.DecMapUint16Int64V(*vp, true, d); changed {
  22646. *vp = v
  22647. }
  22648. }
  22649. func (_ fastpathT) DecMapUint16Int64V(v map[uint16]int64, canChange bool,
  22650. d *Decoder) (_ map[uint16]int64, changed bool) {
  22651. dd, esep := d.d, d.hh.hasElemSeparators()
  22652. containerLen := dd.ReadMapStart()
  22653. if canChange && v == nil {
  22654. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  22655. v = make(map[uint16]int64, xlen)
  22656. changed = true
  22657. }
  22658. if containerLen == 0 {
  22659. dd.ReadMapEnd()
  22660. return v, changed
  22661. }
  22662. var mk uint16
  22663. var mv int64
  22664. hasLen := containerLen > 0
  22665. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22666. if esep {
  22667. dd.ReadMapElemKey()
  22668. }
  22669. mk = uint16(dd.DecodeUint(16))
  22670. if esep {
  22671. dd.ReadMapElemValue()
  22672. }
  22673. if dd.TryDecodeAsNil() {
  22674. if d.h.DeleteOnNilMapValue {
  22675. delete(v, mk)
  22676. } else {
  22677. v[mk] = 0
  22678. }
  22679. continue
  22680. }
  22681. mv = dd.DecodeInt(64)
  22682. if v != nil {
  22683. v[mk] = mv
  22684. }
  22685. }
  22686. dd.ReadMapEnd()
  22687. return v, changed
  22688. }
  22689. func (d *Decoder) fastpathDecMapUint16Float32R(f *codecFnInfo, rv reflect.Value) {
  22690. if rv.Kind() == reflect.Ptr {
  22691. vp := rv2i(rv).(*map[uint16]float32)
  22692. if v, changed := fastpathTV.DecMapUint16Float32V(*vp, true, d); changed {
  22693. *vp = v
  22694. }
  22695. return
  22696. }
  22697. fastpathTV.DecMapUint16Float32V(rv2i(rv).(map[uint16]float32), false, d)
  22698. }
  22699. func (f fastpathT) DecMapUint16Float32X(vp *map[uint16]float32, d *Decoder) {
  22700. if v, changed := f.DecMapUint16Float32V(*vp, true, d); changed {
  22701. *vp = v
  22702. }
  22703. }
  22704. func (_ fastpathT) DecMapUint16Float32V(v map[uint16]float32, canChange bool,
  22705. d *Decoder) (_ map[uint16]float32, changed bool) {
  22706. dd, esep := d.d, d.hh.hasElemSeparators()
  22707. containerLen := dd.ReadMapStart()
  22708. if canChange && v == nil {
  22709. xlen := decInferLen(containerLen, d.h.MaxInitLen, 6)
  22710. v = make(map[uint16]float32, xlen)
  22711. changed = true
  22712. }
  22713. if containerLen == 0 {
  22714. dd.ReadMapEnd()
  22715. return v, changed
  22716. }
  22717. var mk uint16
  22718. var mv float32
  22719. hasLen := containerLen > 0
  22720. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22721. if esep {
  22722. dd.ReadMapElemKey()
  22723. }
  22724. mk = uint16(dd.DecodeUint(16))
  22725. if esep {
  22726. dd.ReadMapElemValue()
  22727. }
  22728. if dd.TryDecodeAsNil() {
  22729. if d.h.DeleteOnNilMapValue {
  22730. delete(v, mk)
  22731. } else {
  22732. v[mk] = 0
  22733. }
  22734. continue
  22735. }
  22736. mv = float32(dd.DecodeFloat(true))
  22737. if v != nil {
  22738. v[mk] = mv
  22739. }
  22740. }
  22741. dd.ReadMapEnd()
  22742. return v, changed
  22743. }
  22744. func (d *Decoder) fastpathDecMapUint16Float64R(f *codecFnInfo, rv reflect.Value) {
  22745. if rv.Kind() == reflect.Ptr {
  22746. vp := rv2i(rv).(*map[uint16]float64)
  22747. if v, changed := fastpathTV.DecMapUint16Float64V(*vp, true, d); changed {
  22748. *vp = v
  22749. }
  22750. return
  22751. }
  22752. fastpathTV.DecMapUint16Float64V(rv2i(rv).(map[uint16]float64), false, d)
  22753. }
  22754. func (f fastpathT) DecMapUint16Float64X(vp *map[uint16]float64, d *Decoder) {
  22755. if v, changed := f.DecMapUint16Float64V(*vp, true, d); changed {
  22756. *vp = v
  22757. }
  22758. }
  22759. func (_ fastpathT) DecMapUint16Float64V(v map[uint16]float64, canChange bool,
  22760. d *Decoder) (_ map[uint16]float64, changed bool) {
  22761. dd, esep := d.d, d.hh.hasElemSeparators()
  22762. containerLen := dd.ReadMapStart()
  22763. if canChange && v == nil {
  22764. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  22765. v = make(map[uint16]float64, xlen)
  22766. changed = true
  22767. }
  22768. if containerLen == 0 {
  22769. dd.ReadMapEnd()
  22770. return v, changed
  22771. }
  22772. var mk uint16
  22773. var mv float64
  22774. hasLen := containerLen > 0
  22775. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22776. if esep {
  22777. dd.ReadMapElemKey()
  22778. }
  22779. mk = uint16(dd.DecodeUint(16))
  22780. if esep {
  22781. dd.ReadMapElemValue()
  22782. }
  22783. if dd.TryDecodeAsNil() {
  22784. if d.h.DeleteOnNilMapValue {
  22785. delete(v, mk)
  22786. } else {
  22787. v[mk] = 0
  22788. }
  22789. continue
  22790. }
  22791. mv = dd.DecodeFloat(false)
  22792. if v != nil {
  22793. v[mk] = mv
  22794. }
  22795. }
  22796. dd.ReadMapEnd()
  22797. return v, changed
  22798. }
  22799. func (d *Decoder) fastpathDecMapUint16BoolR(f *codecFnInfo, rv reflect.Value) {
  22800. if rv.Kind() == reflect.Ptr {
  22801. vp := rv2i(rv).(*map[uint16]bool)
  22802. if v, changed := fastpathTV.DecMapUint16BoolV(*vp, true, d); changed {
  22803. *vp = v
  22804. }
  22805. return
  22806. }
  22807. fastpathTV.DecMapUint16BoolV(rv2i(rv).(map[uint16]bool), false, d)
  22808. }
  22809. func (f fastpathT) DecMapUint16BoolX(vp *map[uint16]bool, d *Decoder) {
  22810. if v, changed := f.DecMapUint16BoolV(*vp, true, d); changed {
  22811. *vp = v
  22812. }
  22813. }
  22814. func (_ fastpathT) DecMapUint16BoolV(v map[uint16]bool, canChange bool,
  22815. d *Decoder) (_ map[uint16]bool, changed bool) {
  22816. dd, esep := d.d, d.hh.hasElemSeparators()
  22817. containerLen := dd.ReadMapStart()
  22818. if canChange && v == nil {
  22819. xlen := decInferLen(containerLen, d.h.MaxInitLen, 3)
  22820. v = make(map[uint16]bool, xlen)
  22821. changed = true
  22822. }
  22823. if containerLen == 0 {
  22824. dd.ReadMapEnd()
  22825. return v, changed
  22826. }
  22827. var mk uint16
  22828. var mv bool
  22829. hasLen := containerLen > 0
  22830. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22831. if esep {
  22832. dd.ReadMapElemKey()
  22833. }
  22834. mk = uint16(dd.DecodeUint(16))
  22835. if esep {
  22836. dd.ReadMapElemValue()
  22837. }
  22838. if dd.TryDecodeAsNil() {
  22839. if d.h.DeleteOnNilMapValue {
  22840. delete(v, mk)
  22841. } else {
  22842. v[mk] = false
  22843. }
  22844. continue
  22845. }
  22846. mv = dd.DecodeBool()
  22847. if v != nil {
  22848. v[mk] = mv
  22849. }
  22850. }
  22851. dd.ReadMapEnd()
  22852. return v, changed
  22853. }
  22854. func (d *Decoder) fastpathDecMapUint32IntfR(f *codecFnInfo, rv reflect.Value) {
  22855. if rv.Kind() == reflect.Ptr {
  22856. vp := rv2i(rv).(*map[uint32]interface{})
  22857. if v, changed := fastpathTV.DecMapUint32IntfV(*vp, true, d); changed {
  22858. *vp = v
  22859. }
  22860. return
  22861. }
  22862. fastpathTV.DecMapUint32IntfV(rv2i(rv).(map[uint32]interface{}), false, d)
  22863. }
  22864. func (f fastpathT) DecMapUint32IntfX(vp *map[uint32]interface{}, d *Decoder) {
  22865. if v, changed := f.DecMapUint32IntfV(*vp, true, d); changed {
  22866. *vp = v
  22867. }
  22868. }
  22869. func (_ fastpathT) DecMapUint32IntfV(v map[uint32]interface{}, canChange bool,
  22870. d *Decoder) (_ map[uint32]interface{}, changed bool) {
  22871. dd, esep := d.d, d.hh.hasElemSeparators()
  22872. containerLen := dd.ReadMapStart()
  22873. if canChange && v == nil {
  22874. xlen := decInferLen(containerLen, d.h.MaxInitLen, 20)
  22875. v = make(map[uint32]interface{}, xlen)
  22876. changed = true
  22877. }
  22878. if containerLen == 0 {
  22879. dd.ReadMapEnd()
  22880. return v, changed
  22881. }
  22882. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  22883. var mk uint32
  22884. var mv interface{}
  22885. hasLen := containerLen > 0
  22886. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22887. if esep {
  22888. dd.ReadMapElemKey()
  22889. }
  22890. mk = uint32(dd.DecodeUint(32))
  22891. if esep {
  22892. dd.ReadMapElemValue()
  22893. }
  22894. if dd.TryDecodeAsNil() {
  22895. if d.h.DeleteOnNilMapValue {
  22896. delete(v, mk)
  22897. } else {
  22898. v[mk] = nil
  22899. }
  22900. continue
  22901. }
  22902. if mapGet {
  22903. mv = v[mk]
  22904. } else {
  22905. mv = nil
  22906. }
  22907. d.decode(&mv)
  22908. if v != nil {
  22909. v[mk] = mv
  22910. }
  22911. }
  22912. dd.ReadMapEnd()
  22913. return v, changed
  22914. }
  22915. func (d *Decoder) fastpathDecMapUint32StringR(f *codecFnInfo, rv reflect.Value) {
  22916. if rv.Kind() == reflect.Ptr {
  22917. vp := rv2i(rv).(*map[uint32]string)
  22918. if v, changed := fastpathTV.DecMapUint32StringV(*vp, true, d); changed {
  22919. *vp = v
  22920. }
  22921. return
  22922. }
  22923. fastpathTV.DecMapUint32StringV(rv2i(rv).(map[uint32]string), false, d)
  22924. }
  22925. func (f fastpathT) DecMapUint32StringX(vp *map[uint32]string, d *Decoder) {
  22926. if v, changed := f.DecMapUint32StringV(*vp, true, d); changed {
  22927. *vp = v
  22928. }
  22929. }
  22930. func (_ fastpathT) DecMapUint32StringV(v map[uint32]string, canChange bool,
  22931. d *Decoder) (_ map[uint32]string, changed bool) {
  22932. dd, esep := d.d, d.hh.hasElemSeparators()
  22933. containerLen := dd.ReadMapStart()
  22934. if canChange && v == nil {
  22935. xlen := decInferLen(containerLen, d.h.MaxInitLen, 20)
  22936. v = make(map[uint32]string, xlen)
  22937. changed = true
  22938. }
  22939. if containerLen == 0 {
  22940. dd.ReadMapEnd()
  22941. return v, changed
  22942. }
  22943. var mk uint32
  22944. var mv string
  22945. hasLen := containerLen > 0
  22946. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22947. if esep {
  22948. dd.ReadMapElemKey()
  22949. }
  22950. mk = uint32(dd.DecodeUint(32))
  22951. if esep {
  22952. dd.ReadMapElemValue()
  22953. }
  22954. if dd.TryDecodeAsNil() {
  22955. if d.h.DeleteOnNilMapValue {
  22956. delete(v, mk)
  22957. } else {
  22958. v[mk] = ""
  22959. }
  22960. continue
  22961. }
  22962. mv = dd.DecodeString()
  22963. if v != nil {
  22964. v[mk] = mv
  22965. }
  22966. }
  22967. dd.ReadMapEnd()
  22968. return v, changed
  22969. }
  22970. func (d *Decoder) fastpathDecMapUint32UintR(f *codecFnInfo, rv reflect.Value) {
  22971. if rv.Kind() == reflect.Ptr {
  22972. vp := rv2i(rv).(*map[uint32]uint)
  22973. if v, changed := fastpathTV.DecMapUint32UintV(*vp, true, d); changed {
  22974. *vp = v
  22975. }
  22976. return
  22977. }
  22978. fastpathTV.DecMapUint32UintV(rv2i(rv).(map[uint32]uint), false, d)
  22979. }
  22980. func (f fastpathT) DecMapUint32UintX(vp *map[uint32]uint, d *Decoder) {
  22981. if v, changed := f.DecMapUint32UintV(*vp, true, d); changed {
  22982. *vp = v
  22983. }
  22984. }
  22985. func (_ fastpathT) DecMapUint32UintV(v map[uint32]uint, canChange bool,
  22986. d *Decoder) (_ map[uint32]uint, changed bool) {
  22987. dd, esep := d.d, d.hh.hasElemSeparators()
  22988. containerLen := dd.ReadMapStart()
  22989. if canChange && v == nil {
  22990. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  22991. v = make(map[uint32]uint, xlen)
  22992. changed = true
  22993. }
  22994. if containerLen == 0 {
  22995. dd.ReadMapEnd()
  22996. return v, changed
  22997. }
  22998. var mk uint32
  22999. var mv uint
  23000. hasLen := containerLen > 0
  23001. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23002. if esep {
  23003. dd.ReadMapElemKey()
  23004. }
  23005. mk = uint32(dd.DecodeUint(32))
  23006. if esep {
  23007. dd.ReadMapElemValue()
  23008. }
  23009. if dd.TryDecodeAsNil() {
  23010. if d.h.DeleteOnNilMapValue {
  23011. delete(v, mk)
  23012. } else {
  23013. v[mk] = 0
  23014. }
  23015. continue
  23016. }
  23017. mv = uint(dd.DecodeUint(uintBitsize))
  23018. if v != nil {
  23019. v[mk] = mv
  23020. }
  23021. }
  23022. dd.ReadMapEnd()
  23023. return v, changed
  23024. }
  23025. func (d *Decoder) fastpathDecMapUint32Uint8R(f *codecFnInfo, rv reflect.Value) {
  23026. if rv.Kind() == reflect.Ptr {
  23027. vp := rv2i(rv).(*map[uint32]uint8)
  23028. if v, changed := fastpathTV.DecMapUint32Uint8V(*vp, true, d); changed {
  23029. *vp = v
  23030. }
  23031. return
  23032. }
  23033. fastpathTV.DecMapUint32Uint8V(rv2i(rv).(map[uint32]uint8), false, d)
  23034. }
  23035. func (f fastpathT) DecMapUint32Uint8X(vp *map[uint32]uint8, d *Decoder) {
  23036. if v, changed := f.DecMapUint32Uint8V(*vp, true, d); changed {
  23037. *vp = v
  23038. }
  23039. }
  23040. func (_ fastpathT) DecMapUint32Uint8V(v map[uint32]uint8, canChange bool,
  23041. d *Decoder) (_ map[uint32]uint8, changed bool) {
  23042. dd, esep := d.d, d.hh.hasElemSeparators()
  23043. containerLen := dd.ReadMapStart()
  23044. if canChange && v == nil {
  23045. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  23046. v = make(map[uint32]uint8, xlen)
  23047. changed = true
  23048. }
  23049. if containerLen == 0 {
  23050. dd.ReadMapEnd()
  23051. return v, changed
  23052. }
  23053. var mk uint32
  23054. var mv uint8
  23055. hasLen := containerLen > 0
  23056. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23057. if esep {
  23058. dd.ReadMapElemKey()
  23059. }
  23060. mk = uint32(dd.DecodeUint(32))
  23061. if esep {
  23062. dd.ReadMapElemValue()
  23063. }
  23064. if dd.TryDecodeAsNil() {
  23065. if d.h.DeleteOnNilMapValue {
  23066. delete(v, mk)
  23067. } else {
  23068. v[mk] = 0
  23069. }
  23070. continue
  23071. }
  23072. mv = uint8(dd.DecodeUint(8))
  23073. if v != nil {
  23074. v[mk] = mv
  23075. }
  23076. }
  23077. dd.ReadMapEnd()
  23078. return v, changed
  23079. }
  23080. func (d *Decoder) fastpathDecMapUint32Uint16R(f *codecFnInfo, rv reflect.Value) {
  23081. if rv.Kind() == reflect.Ptr {
  23082. vp := rv2i(rv).(*map[uint32]uint16)
  23083. if v, changed := fastpathTV.DecMapUint32Uint16V(*vp, true, d); changed {
  23084. *vp = v
  23085. }
  23086. return
  23087. }
  23088. fastpathTV.DecMapUint32Uint16V(rv2i(rv).(map[uint32]uint16), false, d)
  23089. }
  23090. func (f fastpathT) DecMapUint32Uint16X(vp *map[uint32]uint16, d *Decoder) {
  23091. if v, changed := f.DecMapUint32Uint16V(*vp, true, d); changed {
  23092. *vp = v
  23093. }
  23094. }
  23095. func (_ fastpathT) DecMapUint32Uint16V(v map[uint32]uint16, canChange bool,
  23096. d *Decoder) (_ map[uint32]uint16, changed bool) {
  23097. dd, esep := d.d, d.hh.hasElemSeparators()
  23098. containerLen := dd.ReadMapStart()
  23099. if canChange && v == nil {
  23100. xlen := decInferLen(containerLen, d.h.MaxInitLen, 6)
  23101. v = make(map[uint32]uint16, xlen)
  23102. changed = true
  23103. }
  23104. if containerLen == 0 {
  23105. dd.ReadMapEnd()
  23106. return v, changed
  23107. }
  23108. var mk uint32
  23109. var mv uint16
  23110. hasLen := containerLen > 0
  23111. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23112. if esep {
  23113. dd.ReadMapElemKey()
  23114. }
  23115. mk = uint32(dd.DecodeUint(32))
  23116. if esep {
  23117. dd.ReadMapElemValue()
  23118. }
  23119. if dd.TryDecodeAsNil() {
  23120. if d.h.DeleteOnNilMapValue {
  23121. delete(v, mk)
  23122. } else {
  23123. v[mk] = 0
  23124. }
  23125. continue
  23126. }
  23127. mv = uint16(dd.DecodeUint(16))
  23128. if v != nil {
  23129. v[mk] = mv
  23130. }
  23131. }
  23132. dd.ReadMapEnd()
  23133. return v, changed
  23134. }
  23135. func (d *Decoder) fastpathDecMapUint32Uint32R(f *codecFnInfo, rv reflect.Value) {
  23136. if rv.Kind() == reflect.Ptr {
  23137. vp := rv2i(rv).(*map[uint32]uint32)
  23138. if v, changed := fastpathTV.DecMapUint32Uint32V(*vp, true, d); changed {
  23139. *vp = v
  23140. }
  23141. return
  23142. }
  23143. fastpathTV.DecMapUint32Uint32V(rv2i(rv).(map[uint32]uint32), false, d)
  23144. }
  23145. func (f fastpathT) DecMapUint32Uint32X(vp *map[uint32]uint32, d *Decoder) {
  23146. if v, changed := f.DecMapUint32Uint32V(*vp, true, d); changed {
  23147. *vp = v
  23148. }
  23149. }
  23150. func (_ fastpathT) DecMapUint32Uint32V(v map[uint32]uint32, canChange bool,
  23151. d *Decoder) (_ map[uint32]uint32, changed bool) {
  23152. dd, esep := d.d, d.hh.hasElemSeparators()
  23153. containerLen := dd.ReadMapStart()
  23154. if canChange && v == nil {
  23155. xlen := decInferLen(containerLen, d.h.MaxInitLen, 8)
  23156. v = make(map[uint32]uint32, xlen)
  23157. changed = true
  23158. }
  23159. if containerLen == 0 {
  23160. dd.ReadMapEnd()
  23161. return v, changed
  23162. }
  23163. var mk uint32
  23164. var mv uint32
  23165. hasLen := containerLen > 0
  23166. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23167. if esep {
  23168. dd.ReadMapElemKey()
  23169. }
  23170. mk = uint32(dd.DecodeUint(32))
  23171. if esep {
  23172. dd.ReadMapElemValue()
  23173. }
  23174. if dd.TryDecodeAsNil() {
  23175. if d.h.DeleteOnNilMapValue {
  23176. delete(v, mk)
  23177. } else {
  23178. v[mk] = 0
  23179. }
  23180. continue
  23181. }
  23182. mv = uint32(dd.DecodeUint(32))
  23183. if v != nil {
  23184. v[mk] = mv
  23185. }
  23186. }
  23187. dd.ReadMapEnd()
  23188. return v, changed
  23189. }
  23190. func (d *Decoder) fastpathDecMapUint32Uint64R(f *codecFnInfo, rv reflect.Value) {
  23191. if rv.Kind() == reflect.Ptr {
  23192. vp := rv2i(rv).(*map[uint32]uint64)
  23193. if v, changed := fastpathTV.DecMapUint32Uint64V(*vp, true, d); changed {
  23194. *vp = v
  23195. }
  23196. return
  23197. }
  23198. fastpathTV.DecMapUint32Uint64V(rv2i(rv).(map[uint32]uint64), false, d)
  23199. }
  23200. func (f fastpathT) DecMapUint32Uint64X(vp *map[uint32]uint64, d *Decoder) {
  23201. if v, changed := f.DecMapUint32Uint64V(*vp, true, d); changed {
  23202. *vp = v
  23203. }
  23204. }
  23205. func (_ fastpathT) DecMapUint32Uint64V(v map[uint32]uint64, canChange bool,
  23206. d *Decoder) (_ map[uint32]uint64, changed bool) {
  23207. dd, esep := d.d, d.hh.hasElemSeparators()
  23208. containerLen := dd.ReadMapStart()
  23209. if canChange && v == nil {
  23210. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  23211. v = make(map[uint32]uint64, xlen)
  23212. changed = true
  23213. }
  23214. if containerLen == 0 {
  23215. dd.ReadMapEnd()
  23216. return v, changed
  23217. }
  23218. var mk uint32
  23219. var mv uint64
  23220. hasLen := containerLen > 0
  23221. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23222. if esep {
  23223. dd.ReadMapElemKey()
  23224. }
  23225. mk = uint32(dd.DecodeUint(32))
  23226. if esep {
  23227. dd.ReadMapElemValue()
  23228. }
  23229. if dd.TryDecodeAsNil() {
  23230. if d.h.DeleteOnNilMapValue {
  23231. delete(v, mk)
  23232. } else {
  23233. v[mk] = 0
  23234. }
  23235. continue
  23236. }
  23237. mv = dd.DecodeUint(64)
  23238. if v != nil {
  23239. v[mk] = mv
  23240. }
  23241. }
  23242. dd.ReadMapEnd()
  23243. return v, changed
  23244. }
  23245. func (d *Decoder) fastpathDecMapUint32UintptrR(f *codecFnInfo, rv reflect.Value) {
  23246. if rv.Kind() == reflect.Ptr {
  23247. vp := rv2i(rv).(*map[uint32]uintptr)
  23248. if v, changed := fastpathTV.DecMapUint32UintptrV(*vp, true, d); changed {
  23249. *vp = v
  23250. }
  23251. return
  23252. }
  23253. fastpathTV.DecMapUint32UintptrV(rv2i(rv).(map[uint32]uintptr), false, d)
  23254. }
  23255. func (f fastpathT) DecMapUint32UintptrX(vp *map[uint32]uintptr, d *Decoder) {
  23256. if v, changed := f.DecMapUint32UintptrV(*vp, true, d); changed {
  23257. *vp = v
  23258. }
  23259. }
  23260. func (_ fastpathT) DecMapUint32UintptrV(v map[uint32]uintptr, canChange bool,
  23261. d *Decoder) (_ map[uint32]uintptr, changed bool) {
  23262. dd, esep := d.d, d.hh.hasElemSeparators()
  23263. containerLen := dd.ReadMapStart()
  23264. if canChange && v == nil {
  23265. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  23266. v = make(map[uint32]uintptr, xlen)
  23267. changed = true
  23268. }
  23269. if containerLen == 0 {
  23270. dd.ReadMapEnd()
  23271. return v, changed
  23272. }
  23273. var mk uint32
  23274. var mv uintptr
  23275. hasLen := containerLen > 0
  23276. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23277. if esep {
  23278. dd.ReadMapElemKey()
  23279. }
  23280. mk = uint32(dd.DecodeUint(32))
  23281. if esep {
  23282. dd.ReadMapElemValue()
  23283. }
  23284. if dd.TryDecodeAsNil() {
  23285. if d.h.DeleteOnNilMapValue {
  23286. delete(v, mk)
  23287. } else {
  23288. v[mk] = 0
  23289. }
  23290. continue
  23291. }
  23292. mv = uintptr(dd.DecodeUint(uintBitsize))
  23293. if v != nil {
  23294. v[mk] = mv
  23295. }
  23296. }
  23297. dd.ReadMapEnd()
  23298. return v, changed
  23299. }
  23300. func (d *Decoder) fastpathDecMapUint32IntR(f *codecFnInfo, rv reflect.Value) {
  23301. if rv.Kind() == reflect.Ptr {
  23302. vp := rv2i(rv).(*map[uint32]int)
  23303. if v, changed := fastpathTV.DecMapUint32IntV(*vp, true, d); changed {
  23304. *vp = v
  23305. }
  23306. return
  23307. }
  23308. fastpathTV.DecMapUint32IntV(rv2i(rv).(map[uint32]int), false, d)
  23309. }
  23310. func (f fastpathT) DecMapUint32IntX(vp *map[uint32]int, d *Decoder) {
  23311. if v, changed := f.DecMapUint32IntV(*vp, true, d); changed {
  23312. *vp = v
  23313. }
  23314. }
  23315. func (_ fastpathT) DecMapUint32IntV(v map[uint32]int, canChange bool,
  23316. d *Decoder) (_ map[uint32]int, changed bool) {
  23317. dd, esep := d.d, d.hh.hasElemSeparators()
  23318. containerLen := dd.ReadMapStart()
  23319. if canChange && v == nil {
  23320. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  23321. v = make(map[uint32]int, xlen)
  23322. changed = true
  23323. }
  23324. if containerLen == 0 {
  23325. dd.ReadMapEnd()
  23326. return v, changed
  23327. }
  23328. var mk uint32
  23329. var mv int
  23330. hasLen := containerLen > 0
  23331. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23332. if esep {
  23333. dd.ReadMapElemKey()
  23334. }
  23335. mk = uint32(dd.DecodeUint(32))
  23336. if esep {
  23337. dd.ReadMapElemValue()
  23338. }
  23339. if dd.TryDecodeAsNil() {
  23340. if d.h.DeleteOnNilMapValue {
  23341. delete(v, mk)
  23342. } else {
  23343. v[mk] = 0
  23344. }
  23345. continue
  23346. }
  23347. mv = int(dd.DecodeInt(intBitsize))
  23348. if v != nil {
  23349. v[mk] = mv
  23350. }
  23351. }
  23352. dd.ReadMapEnd()
  23353. return v, changed
  23354. }
  23355. func (d *Decoder) fastpathDecMapUint32Int8R(f *codecFnInfo, rv reflect.Value) {
  23356. if rv.Kind() == reflect.Ptr {
  23357. vp := rv2i(rv).(*map[uint32]int8)
  23358. if v, changed := fastpathTV.DecMapUint32Int8V(*vp, true, d); changed {
  23359. *vp = v
  23360. }
  23361. return
  23362. }
  23363. fastpathTV.DecMapUint32Int8V(rv2i(rv).(map[uint32]int8), false, d)
  23364. }
  23365. func (f fastpathT) DecMapUint32Int8X(vp *map[uint32]int8, d *Decoder) {
  23366. if v, changed := f.DecMapUint32Int8V(*vp, true, d); changed {
  23367. *vp = v
  23368. }
  23369. }
  23370. func (_ fastpathT) DecMapUint32Int8V(v map[uint32]int8, canChange bool,
  23371. d *Decoder) (_ map[uint32]int8, changed bool) {
  23372. dd, esep := d.d, d.hh.hasElemSeparators()
  23373. containerLen := dd.ReadMapStart()
  23374. if canChange && v == nil {
  23375. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  23376. v = make(map[uint32]int8, xlen)
  23377. changed = true
  23378. }
  23379. if containerLen == 0 {
  23380. dd.ReadMapEnd()
  23381. return v, changed
  23382. }
  23383. var mk uint32
  23384. var mv int8
  23385. hasLen := containerLen > 0
  23386. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23387. if esep {
  23388. dd.ReadMapElemKey()
  23389. }
  23390. mk = uint32(dd.DecodeUint(32))
  23391. if esep {
  23392. dd.ReadMapElemValue()
  23393. }
  23394. if dd.TryDecodeAsNil() {
  23395. if d.h.DeleteOnNilMapValue {
  23396. delete(v, mk)
  23397. } else {
  23398. v[mk] = 0
  23399. }
  23400. continue
  23401. }
  23402. mv = int8(dd.DecodeInt(8))
  23403. if v != nil {
  23404. v[mk] = mv
  23405. }
  23406. }
  23407. dd.ReadMapEnd()
  23408. return v, changed
  23409. }
  23410. func (d *Decoder) fastpathDecMapUint32Int16R(f *codecFnInfo, rv reflect.Value) {
  23411. if rv.Kind() == reflect.Ptr {
  23412. vp := rv2i(rv).(*map[uint32]int16)
  23413. if v, changed := fastpathTV.DecMapUint32Int16V(*vp, true, d); changed {
  23414. *vp = v
  23415. }
  23416. return
  23417. }
  23418. fastpathTV.DecMapUint32Int16V(rv2i(rv).(map[uint32]int16), false, d)
  23419. }
  23420. func (f fastpathT) DecMapUint32Int16X(vp *map[uint32]int16, d *Decoder) {
  23421. if v, changed := f.DecMapUint32Int16V(*vp, true, d); changed {
  23422. *vp = v
  23423. }
  23424. }
  23425. func (_ fastpathT) DecMapUint32Int16V(v map[uint32]int16, canChange bool,
  23426. d *Decoder) (_ map[uint32]int16, changed bool) {
  23427. dd, esep := d.d, d.hh.hasElemSeparators()
  23428. containerLen := dd.ReadMapStart()
  23429. if canChange && v == nil {
  23430. xlen := decInferLen(containerLen, d.h.MaxInitLen, 6)
  23431. v = make(map[uint32]int16, xlen)
  23432. changed = true
  23433. }
  23434. if containerLen == 0 {
  23435. dd.ReadMapEnd()
  23436. return v, changed
  23437. }
  23438. var mk uint32
  23439. var mv int16
  23440. hasLen := containerLen > 0
  23441. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23442. if esep {
  23443. dd.ReadMapElemKey()
  23444. }
  23445. mk = uint32(dd.DecodeUint(32))
  23446. if esep {
  23447. dd.ReadMapElemValue()
  23448. }
  23449. if dd.TryDecodeAsNil() {
  23450. if d.h.DeleteOnNilMapValue {
  23451. delete(v, mk)
  23452. } else {
  23453. v[mk] = 0
  23454. }
  23455. continue
  23456. }
  23457. mv = int16(dd.DecodeInt(16))
  23458. if v != nil {
  23459. v[mk] = mv
  23460. }
  23461. }
  23462. dd.ReadMapEnd()
  23463. return v, changed
  23464. }
  23465. func (d *Decoder) fastpathDecMapUint32Int32R(f *codecFnInfo, rv reflect.Value) {
  23466. if rv.Kind() == reflect.Ptr {
  23467. vp := rv2i(rv).(*map[uint32]int32)
  23468. if v, changed := fastpathTV.DecMapUint32Int32V(*vp, true, d); changed {
  23469. *vp = v
  23470. }
  23471. return
  23472. }
  23473. fastpathTV.DecMapUint32Int32V(rv2i(rv).(map[uint32]int32), false, d)
  23474. }
  23475. func (f fastpathT) DecMapUint32Int32X(vp *map[uint32]int32, d *Decoder) {
  23476. if v, changed := f.DecMapUint32Int32V(*vp, true, d); changed {
  23477. *vp = v
  23478. }
  23479. }
  23480. func (_ fastpathT) DecMapUint32Int32V(v map[uint32]int32, canChange bool,
  23481. d *Decoder) (_ map[uint32]int32, changed bool) {
  23482. dd, esep := d.d, d.hh.hasElemSeparators()
  23483. containerLen := dd.ReadMapStart()
  23484. if canChange && v == nil {
  23485. xlen := decInferLen(containerLen, d.h.MaxInitLen, 8)
  23486. v = make(map[uint32]int32, xlen)
  23487. changed = true
  23488. }
  23489. if containerLen == 0 {
  23490. dd.ReadMapEnd()
  23491. return v, changed
  23492. }
  23493. var mk uint32
  23494. var mv int32
  23495. hasLen := containerLen > 0
  23496. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23497. if esep {
  23498. dd.ReadMapElemKey()
  23499. }
  23500. mk = uint32(dd.DecodeUint(32))
  23501. if esep {
  23502. dd.ReadMapElemValue()
  23503. }
  23504. if dd.TryDecodeAsNil() {
  23505. if d.h.DeleteOnNilMapValue {
  23506. delete(v, mk)
  23507. } else {
  23508. v[mk] = 0
  23509. }
  23510. continue
  23511. }
  23512. mv = int32(dd.DecodeInt(32))
  23513. if v != nil {
  23514. v[mk] = mv
  23515. }
  23516. }
  23517. dd.ReadMapEnd()
  23518. return v, changed
  23519. }
  23520. func (d *Decoder) fastpathDecMapUint32Int64R(f *codecFnInfo, rv reflect.Value) {
  23521. if rv.Kind() == reflect.Ptr {
  23522. vp := rv2i(rv).(*map[uint32]int64)
  23523. if v, changed := fastpathTV.DecMapUint32Int64V(*vp, true, d); changed {
  23524. *vp = v
  23525. }
  23526. return
  23527. }
  23528. fastpathTV.DecMapUint32Int64V(rv2i(rv).(map[uint32]int64), false, d)
  23529. }
  23530. func (f fastpathT) DecMapUint32Int64X(vp *map[uint32]int64, d *Decoder) {
  23531. if v, changed := f.DecMapUint32Int64V(*vp, true, d); changed {
  23532. *vp = v
  23533. }
  23534. }
  23535. func (_ fastpathT) DecMapUint32Int64V(v map[uint32]int64, canChange bool,
  23536. d *Decoder) (_ map[uint32]int64, changed bool) {
  23537. dd, esep := d.d, d.hh.hasElemSeparators()
  23538. containerLen := dd.ReadMapStart()
  23539. if canChange && v == nil {
  23540. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  23541. v = make(map[uint32]int64, xlen)
  23542. changed = true
  23543. }
  23544. if containerLen == 0 {
  23545. dd.ReadMapEnd()
  23546. return v, changed
  23547. }
  23548. var mk uint32
  23549. var mv int64
  23550. hasLen := containerLen > 0
  23551. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23552. if esep {
  23553. dd.ReadMapElemKey()
  23554. }
  23555. mk = uint32(dd.DecodeUint(32))
  23556. if esep {
  23557. dd.ReadMapElemValue()
  23558. }
  23559. if dd.TryDecodeAsNil() {
  23560. if d.h.DeleteOnNilMapValue {
  23561. delete(v, mk)
  23562. } else {
  23563. v[mk] = 0
  23564. }
  23565. continue
  23566. }
  23567. mv = dd.DecodeInt(64)
  23568. if v != nil {
  23569. v[mk] = mv
  23570. }
  23571. }
  23572. dd.ReadMapEnd()
  23573. return v, changed
  23574. }
  23575. func (d *Decoder) fastpathDecMapUint32Float32R(f *codecFnInfo, rv reflect.Value) {
  23576. if rv.Kind() == reflect.Ptr {
  23577. vp := rv2i(rv).(*map[uint32]float32)
  23578. if v, changed := fastpathTV.DecMapUint32Float32V(*vp, true, d); changed {
  23579. *vp = v
  23580. }
  23581. return
  23582. }
  23583. fastpathTV.DecMapUint32Float32V(rv2i(rv).(map[uint32]float32), false, d)
  23584. }
  23585. func (f fastpathT) DecMapUint32Float32X(vp *map[uint32]float32, d *Decoder) {
  23586. if v, changed := f.DecMapUint32Float32V(*vp, true, d); changed {
  23587. *vp = v
  23588. }
  23589. }
  23590. func (_ fastpathT) DecMapUint32Float32V(v map[uint32]float32, canChange bool,
  23591. d *Decoder) (_ map[uint32]float32, changed bool) {
  23592. dd, esep := d.d, d.hh.hasElemSeparators()
  23593. containerLen := dd.ReadMapStart()
  23594. if canChange && v == nil {
  23595. xlen := decInferLen(containerLen, d.h.MaxInitLen, 8)
  23596. v = make(map[uint32]float32, xlen)
  23597. changed = true
  23598. }
  23599. if containerLen == 0 {
  23600. dd.ReadMapEnd()
  23601. return v, changed
  23602. }
  23603. var mk uint32
  23604. var mv float32
  23605. hasLen := containerLen > 0
  23606. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23607. if esep {
  23608. dd.ReadMapElemKey()
  23609. }
  23610. mk = uint32(dd.DecodeUint(32))
  23611. if esep {
  23612. dd.ReadMapElemValue()
  23613. }
  23614. if dd.TryDecodeAsNil() {
  23615. if d.h.DeleteOnNilMapValue {
  23616. delete(v, mk)
  23617. } else {
  23618. v[mk] = 0
  23619. }
  23620. continue
  23621. }
  23622. mv = float32(dd.DecodeFloat(true))
  23623. if v != nil {
  23624. v[mk] = mv
  23625. }
  23626. }
  23627. dd.ReadMapEnd()
  23628. return v, changed
  23629. }
  23630. func (d *Decoder) fastpathDecMapUint32Float64R(f *codecFnInfo, rv reflect.Value) {
  23631. if rv.Kind() == reflect.Ptr {
  23632. vp := rv2i(rv).(*map[uint32]float64)
  23633. if v, changed := fastpathTV.DecMapUint32Float64V(*vp, true, d); changed {
  23634. *vp = v
  23635. }
  23636. return
  23637. }
  23638. fastpathTV.DecMapUint32Float64V(rv2i(rv).(map[uint32]float64), false, d)
  23639. }
  23640. func (f fastpathT) DecMapUint32Float64X(vp *map[uint32]float64, d *Decoder) {
  23641. if v, changed := f.DecMapUint32Float64V(*vp, true, d); changed {
  23642. *vp = v
  23643. }
  23644. }
  23645. func (_ fastpathT) DecMapUint32Float64V(v map[uint32]float64, canChange bool,
  23646. d *Decoder) (_ map[uint32]float64, changed bool) {
  23647. dd, esep := d.d, d.hh.hasElemSeparators()
  23648. containerLen := dd.ReadMapStart()
  23649. if canChange && v == nil {
  23650. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  23651. v = make(map[uint32]float64, xlen)
  23652. changed = true
  23653. }
  23654. if containerLen == 0 {
  23655. dd.ReadMapEnd()
  23656. return v, changed
  23657. }
  23658. var mk uint32
  23659. var mv float64
  23660. hasLen := containerLen > 0
  23661. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23662. if esep {
  23663. dd.ReadMapElemKey()
  23664. }
  23665. mk = uint32(dd.DecodeUint(32))
  23666. if esep {
  23667. dd.ReadMapElemValue()
  23668. }
  23669. if dd.TryDecodeAsNil() {
  23670. if d.h.DeleteOnNilMapValue {
  23671. delete(v, mk)
  23672. } else {
  23673. v[mk] = 0
  23674. }
  23675. continue
  23676. }
  23677. mv = dd.DecodeFloat(false)
  23678. if v != nil {
  23679. v[mk] = mv
  23680. }
  23681. }
  23682. dd.ReadMapEnd()
  23683. return v, changed
  23684. }
  23685. func (d *Decoder) fastpathDecMapUint32BoolR(f *codecFnInfo, rv reflect.Value) {
  23686. if rv.Kind() == reflect.Ptr {
  23687. vp := rv2i(rv).(*map[uint32]bool)
  23688. if v, changed := fastpathTV.DecMapUint32BoolV(*vp, true, d); changed {
  23689. *vp = v
  23690. }
  23691. return
  23692. }
  23693. fastpathTV.DecMapUint32BoolV(rv2i(rv).(map[uint32]bool), false, d)
  23694. }
  23695. func (f fastpathT) DecMapUint32BoolX(vp *map[uint32]bool, d *Decoder) {
  23696. if v, changed := f.DecMapUint32BoolV(*vp, true, d); changed {
  23697. *vp = v
  23698. }
  23699. }
  23700. func (_ fastpathT) DecMapUint32BoolV(v map[uint32]bool, canChange bool,
  23701. d *Decoder) (_ map[uint32]bool, changed bool) {
  23702. dd, esep := d.d, d.hh.hasElemSeparators()
  23703. containerLen := dd.ReadMapStart()
  23704. if canChange && v == nil {
  23705. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  23706. v = make(map[uint32]bool, xlen)
  23707. changed = true
  23708. }
  23709. if containerLen == 0 {
  23710. dd.ReadMapEnd()
  23711. return v, changed
  23712. }
  23713. var mk uint32
  23714. var mv bool
  23715. hasLen := containerLen > 0
  23716. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23717. if esep {
  23718. dd.ReadMapElemKey()
  23719. }
  23720. mk = uint32(dd.DecodeUint(32))
  23721. if esep {
  23722. dd.ReadMapElemValue()
  23723. }
  23724. if dd.TryDecodeAsNil() {
  23725. if d.h.DeleteOnNilMapValue {
  23726. delete(v, mk)
  23727. } else {
  23728. v[mk] = false
  23729. }
  23730. continue
  23731. }
  23732. mv = dd.DecodeBool()
  23733. if v != nil {
  23734. v[mk] = mv
  23735. }
  23736. }
  23737. dd.ReadMapEnd()
  23738. return v, changed
  23739. }
  23740. func (d *Decoder) fastpathDecMapUint64IntfR(f *codecFnInfo, rv reflect.Value) {
  23741. if rv.Kind() == reflect.Ptr {
  23742. vp := rv2i(rv).(*map[uint64]interface{})
  23743. if v, changed := fastpathTV.DecMapUint64IntfV(*vp, true, d); changed {
  23744. *vp = v
  23745. }
  23746. return
  23747. }
  23748. fastpathTV.DecMapUint64IntfV(rv2i(rv).(map[uint64]interface{}), false, d)
  23749. }
  23750. func (f fastpathT) DecMapUint64IntfX(vp *map[uint64]interface{}, d *Decoder) {
  23751. if v, changed := f.DecMapUint64IntfV(*vp, true, d); changed {
  23752. *vp = v
  23753. }
  23754. }
  23755. func (_ fastpathT) DecMapUint64IntfV(v map[uint64]interface{}, canChange bool,
  23756. d *Decoder) (_ map[uint64]interface{}, changed bool) {
  23757. dd, esep := d.d, d.hh.hasElemSeparators()
  23758. containerLen := dd.ReadMapStart()
  23759. if canChange && v == nil {
  23760. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  23761. v = make(map[uint64]interface{}, xlen)
  23762. changed = true
  23763. }
  23764. if containerLen == 0 {
  23765. dd.ReadMapEnd()
  23766. return v, changed
  23767. }
  23768. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  23769. var mk uint64
  23770. var mv interface{}
  23771. hasLen := containerLen > 0
  23772. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23773. if esep {
  23774. dd.ReadMapElemKey()
  23775. }
  23776. mk = dd.DecodeUint(64)
  23777. if esep {
  23778. dd.ReadMapElemValue()
  23779. }
  23780. if dd.TryDecodeAsNil() {
  23781. if d.h.DeleteOnNilMapValue {
  23782. delete(v, mk)
  23783. } else {
  23784. v[mk] = nil
  23785. }
  23786. continue
  23787. }
  23788. if mapGet {
  23789. mv = v[mk]
  23790. } else {
  23791. mv = nil
  23792. }
  23793. d.decode(&mv)
  23794. if v != nil {
  23795. v[mk] = mv
  23796. }
  23797. }
  23798. dd.ReadMapEnd()
  23799. return v, changed
  23800. }
  23801. func (d *Decoder) fastpathDecMapUint64StringR(f *codecFnInfo, rv reflect.Value) {
  23802. if rv.Kind() == reflect.Ptr {
  23803. vp := rv2i(rv).(*map[uint64]string)
  23804. if v, changed := fastpathTV.DecMapUint64StringV(*vp, true, d); changed {
  23805. *vp = v
  23806. }
  23807. return
  23808. }
  23809. fastpathTV.DecMapUint64StringV(rv2i(rv).(map[uint64]string), false, d)
  23810. }
  23811. func (f fastpathT) DecMapUint64StringX(vp *map[uint64]string, d *Decoder) {
  23812. if v, changed := f.DecMapUint64StringV(*vp, true, d); changed {
  23813. *vp = v
  23814. }
  23815. }
  23816. func (_ fastpathT) DecMapUint64StringV(v map[uint64]string, canChange bool,
  23817. d *Decoder) (_ map[uint64]string, changed bool) {
  23818. dd, esep := d.d, d.hh.hasElemSeparators()
  23819. containerLen := dd.ReadMapStart()
  23820. if canChange && v == nil {
  23821. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  23822. v = make(map[uint64]string, xlen)
  23823. changed = true
  23824. }
  23825. if containerLen == 0 {
  23826. dd.ReadMapEnd()
  23827. return v, changed
  23828. }
  23829. var mk uint64
  23830. var mv string
  23831. hasLen := containerLen > 0
  23832. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23833. if esep {
  23834. dd.ReadMapElemKey()
  23835. }
  23836. mk = dd.DecodeUint(64)
  23837. if esep {
  23838. dd.ReadMapElemValue()
  23839. }
  23840. if dd.TryDecodeAsNil() {
  23841. if d.h.DeleteOnNilMapValue {
  23842. delete(v, mk)
  23843. } else {
  23844. v[mk] = ""
  23845. }
  23846. continue
  23847. }
  23848. mv = dd.DecodeString()
  23849. if v != nil {
  23850. v[mk] = mv
  23851. }
  23852. }
  23853. dd.ReadMapEnd()
  23854. return v, changed
  23855. }
  23856. func (d *Decoder) fastpathDecMapUint64UintR(f *codecFnInfo, rv reflect.Value) {
  23857. if rv.Kind() == reflect.Ptr {
  23858. vp := rv2i(rv).(*map[uint64]uint)
  23859. if v, changed := fastpathTV.DecMapUint64UintV(*vp, true, d); changed {
  23860. *vp = v
  23861. }
  23862. return
  23863. }
  23864. fastpathTV.DecMapUint64UintV(rv2i(rv).(map[uint64]uint), false, d)
  23865. }
  23866. func (f fastpathT) DecMapUint64UintX(vp *map[uint64]uint, d *Decoder) {
  23867. if v, changed := f.DecMapUint64UintV(*vp, true, d); changed {
  23868. *vp = v
  23869. }
  23870. }
  23871. func (_ fastpathT) DecMapUint64UintV(v map[uint64]uint, canChange bool,
  23872. d *Decoder) (_ map[uint64]uint, changed bool) {
  23873. dd, esep := d.d, d.hh.hasElemSeparators()
  23874. containerLen := dd.ReadMapStart()
  23875. if canChange && v == nil {
  23876. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  23877. v = make(map[uint64]uint, xlen)
  23878. changed = true
  23879. }
  23880. if containerLen == 0 {
  23881. dd.ReadMapEnd()
  23882. return v, changed
  23883. }
  23884. var mk uint64
  23885. var mv uint
  23886. hasLen := containerLen > 0
  23887. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23888. if esep {
  23889. dd.ReadMapElemKey()
  23890. }
  23891. mk = dd.DecodeUint(64)
  23892. if esep {
  23893. dd.ReadMapElemValue()
  23894. }
  23895. if dd.TryDecodeAsNil() {
  23896. if d.h.DeleteOnNilMapValue {
  23897. delete(v, mk)
  23898. } else {
  23899. v[mk] = 0
  23900. }
  23901. continue
  23902. }
  23903. mv = uint(dd.DecodeUint(uintBitsize))
  23904. if v != nil {
  23905. v[mk] = mv
  23906. }
  23907. }
  23908. dd.ReadMapEnd()
  23909. return v, changed
  23910. }
  23911. func (d *Decoder) fastpathDecMapUint64Uint8R(f *codecFnInfo, rv reflect.Value) {
  23912. if rv.Kind() == reflect.Ptr {
  23913. vp := rv2i(rv).(*map[uint64]uint8)
  23914. if v, changed := fastpathTV.DecMapUint64Uint8V(*vp, true, d); changed {
  23915. *vp = v
  23916. }
  23917. return
  23918. }
  23919. fastpathTV.DecMapUint64Uint8V(rv2i(rv).(map[uint64]uint8), false, d)
  23920. }
  23921. func (f fastpathT) DecMapUint64Uint8X(vp *map[uint64]uint8, d *Decoder) {
  23922. if v, changed := f.DecMapUint64Uint8V(*vp, true, d); changed {
  23923. *vp = v
  23924. }
  23925. }
  23926. func (_ fastpathT) DecMapUint64Uint8V(v map[uint64]uint8, canChange bool,
  23927. d *Decoder) (_ map[uint64]uint8, changed bool) {
  23928. dd, esep := d.d, d.hh.hasElemSeparators()
  23929. containerLen := dd.ReadMapStart()
  23930. if canChange && v == nil {
  23931. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  23932. v = make(map[uint64]uint8, xlen)
  23933. changed = true
  23934. }
  23935. if containerLen == 0 {
  23936. dd.ReadMapEnd()
  23937. return v, changed
  23938. }
  23939. var mk uint64
  23940. var mv uint8
  23941. hasLen := containerLen > 0
  23942. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23943. if esep {
  23944. dd.ReadMapElemKey()
  23945. }
  23946. mk = dd.DecodeUint(64)
  23947. if esep {
  23948. dd.ReadMapElemValue()
  23949. }
  23950. if dd.TryDecodeAsNil() {
  23951. if d.h.DeleteOnNilMapValue {
  23952. delete(v, mk)
  23953. } else {
  23954. v[mk] = 0
  23955. }
  23956. continue
  23957. }
  23958. mv = uint8(dd.DecodeUint(8))
  23959. if v != nil {
  23960. v[mk] = mv
  23961. }
  23962. }
  23963. dd.ReadMapEnd()
  23964. return v, changed
  23965. }
  23966. func (d *Decoder) fastpathDecMapUint64Uint16R(f *codecFnInfo, rv reflect.Value) {
  23967. if rv.Kind() == reflect.Ptr {
  23968. vp := rv2i(rv).(*map[uint64]uint16)
  23969. if v, changed := fastpathTV.DecMapUint64Uint16V(*vp, true, d); changed {
  23970. *vp = v
  23971. }
  23972. return
  23973. }
  23974. fastpathTV.DecMapUint64Uint16V(rv2i(rv).(map[uint64]uint16), false, d)
  23975. }
  23976. func (f fastpathT) DecMapUint64Uint16X(vp *map[uint64]uint16, d *Decoder) {
  23977. if v, changed := f.DecMapUint64Uint16V(*vp, true, d); changed {
  23978. *vp = v
  23979. }
  23980. }
  23981. func (_ fastpathT) DecMapUint64Uint16V(v map[uint64]uint16, canChange bool,
  23982. d *Decoder) (_ map[uint64]uint16, changed bool) {
  23983. dd, esep := d.d, d.hh.hasElemSeparators()
  23984. containerLen := dd.ReadMapStart()
  23985. if canChange && v == nil {
  23986. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  23987. v = make(map[uint64]uint16, xlen)
  23988. changed = true
  23989. }
  23990. if containerLen == 0 {
  23991. dd.ReadMapEnd()
  23992. return v, changed
  23993. }
  23994. var mk uint64
  23995. var mv uint16
  23996. hasLen := containerLen > 0
  23997. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23998. if esep {
  23999. dd.ReadMapElemKey()
  24000. }
  24001. mk = dd.DecodeUint(64)
  24002. if esep {
  24003. dd.ReadMapElemValue()
  24004. }
  24005. if dd.TryDecodeAsNil() {
  24006. if d.h.DeleteOnNilMapValue {
  24007. delete(v, mk)
  24008. } else {
  24009. v[mk] = 0
  24010. }
  24011. continue
  24012. }
  24013. mv = uint16(dd.DecodeUint(16))
  24014. if v != nil {
  24015. v[mk] = mv
  24016. }
  24017. }
  24018. dd.ReadMapEnd()
  24019. return v, changed
  24020. }
  24021. func (d *Decoder) fastpathDecMapUint64Uint32R(f *codecFnInfo, rv reflect.Value) {
  24022. if rv.Kind() == reflect.Ptr {
  24023. vp := rv2i(rv).(*map[uint64]uint32)
  24024. if v, changed := fastpathTV.DecMapUint64Uint32V(*vp, true, d); changed {
  24025. *vp = v
  24026. }
  24027. return
  24028. }
  24029. fastpathTV.DecMapUint64Uint32V(rv2i(rv).(map[uint64]uint32), false, d)
  24030. }
  24031. func (f fastpathT) DecMapUint64Uint32X(vp *map[uint64]uint32, d *Decoder) {
  24032. if v, changed := f.DecMapUint64Uint32V(*vp, true, d); changed {
  24033. *vp = v
  24034. }
  24035. }
  24036. func (_ fastpathT) DecMapUint64Uint32V(v map[uint64]uint32, canChange bool,
  24037. d *Decoder) (_ map[uint64]uint32, changed bool) {
  24038. dd, esep := d.d, d.hh.hasElemSeparators()
  24039. containerLen := dd.ReadMapStart()
  24040. if canChange && v == nil {
  24041. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  24042. v = make(map[uint64]uint32, xlen)
  24043. changed = true
  24044. }
  24045. if containerLen == 0 {
  24046. dd.ReadMapEnd()
  24047. return v, changed
  24048. }
  24049. var mk uint64
  24050. var mv uint32
  24051. hasLen := containerLen > 0
  24052. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24053. if esep {
  24054. dd.ReadMapElemKey()
  24055. }
  24056. mk = dd.DecodeUint(64)
  24057. if esep {
  24058. dd.ReadMapElemValue()
  24059. }
  24060. if dd.TryDecodeAsNil() {
  24061. if d.h.DeleteOnNilMapValue {
  24062. delete(v, mk)
  24063. } else {
  24064. v[mk] = 0
  24065. }
  24066. continue
  24067. }
  24068. mv = uint32(dd.DecodeUint(32))
  24069. if v != nil {
  24070. v[mk] = mv
  24071. }
  24072. }
  24073. dd.ReadMapEnd()
  24074. return v, changed
  24075. }
  24076. func (d *Decoder) fastpathDecMapUint64Uint64R(f *codecFnInfo, rv reflect.Value) {
  24077. if rv.Kind() == reflect.Ptr {
  24078. vp := rv2i(rv).(*map[uint64]uint64)
  24079. if v, changed := fastpathTV.DecMapUint64Uint64V(*vp, true, d); changed {
  24080. *vp = v
  24081. }
  24082. return
  24083. }
  24084. fastpathTV.DecMapUint64Uint64V(rv2i(rv).(map[uint64]uint64), false, d)
  24085. }
  24086. func (f fastpathT) DecMapUint64Uint64X(vp *map[uint64]uint64, d *Decoder) {
  24087. if v, changed := f.DecMapUint64Uint64V(*vp, true, d); changed {
  24088. *vp = v
  24089. }
  24090. }
  24091. func (_ fastpathT) DecMapUint64Uint64V(v map[uint64]uint64, canChange bool,
  24092. d *Decoder) (_ map[uint64]uint64, changed bool) {
  24093. dd, esep := d.d, d.hh.hasElemSeparators()
  24094. containerLen := dd.ReadMapStart()
  24095. if canChange && v == nil {
  24096. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  24097. v = make(map[uint64]uint64, xlen)
  24098. changed = true
  24099. }
  24100. if containerLen == 0 {
  24101. dd.ReadMapEnd()
  24102. return v, changed
  24103. }
  24104. var mk uint64
  24105. var mv uint64
  24106. hasLen := containerLen > 0
  24107. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24108. if esep {
  24109. dd.ReadMapElemKey()
  24110. }
  24111. mk = dd.DecodeUint(64)
  24112. if esep {
  24113. dd.ReadMapElemValue()
  24114. }
  24115. if dd.TryDecodeAsNil() {
  24116. if d.h.DeleteOnNilMapValue {
  24117. delete(v, mk)
  24118. } else {
  24119. v[mk] = 0
  24120. }
  24121. continue
  24122. }
  24123. mv = dd.DecodeUint(64)
  24124. if v != nil {
  24125. v[mk] = mv
  24126. }
  24127. }
  24128. dd.ReadMapEnd()
  24129. return v, changed
  24130. }
  24131. func (d *Decoder) fastpathDecMapUint64UintptrR(f *codecFnInfo, rv reflect.Value) {
  24132. if rv.Kind() == reflect.Ptr {
  24133. vp := rv2i(rv).(*map[uint64]uintptr)
  24134. if v, changed := fastpathTV.DecMapUint64UintptrV(*vp, true, d); changed {
  24135. *vp = v
  24136. }
  24137. return
  24138. }
  24139. fastpathTV.DecMapUint64UintptrV(rv2i(rv).(map[uint64]uintptr), false, d)
  24140. }
  24141. func (f fastpathT) DecMapUint64UintptrX(vp *map[uint64]uintptr, d *Decoder) {
  24142. if v, changed := f.DecMapUint64UintptrV(*vp, true, d); changed {
  24143. *vp = v
  24144. }
  24145. }
  24146. func (_ fastpathT) DecMapUint64UintptrV(v map[uint64]uintptr, canChange bool,
  24147. d *Decoder) (_ map[uint64]uintptr, changed bool) {
  24148. dd, esep := d.d, d.hh.hasElemSeparators()
  24149. containerLen := dd.ReadMapStart()
  24150. if canChange && v == nil {
  24151. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  24152. v = make(map[uint64]uintptr, xlen)
  24153. changed = true
  24154. }
  24155. if containerLen == 0 {
  24156. dd.ReadMapEnd()
  24157. return v, changed
  24158. }
  24159. var mk uint64
  24160. var mv uintptr
  24161. hasLen := containerLen > 0
  24162. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24163. if esep {
  24164. dd.ReadMapElemKey()
  24165. }
  24166. mk = dd.DecodeUint(64)
  24167. if esep {
  24168. dd.ReadMapElemValue()
  24169. }
  24170. if dd.TryDecodeAsNil() {
  24171. if d.h.DeleteOnNilMapValue {
  24172. delete(v, mk)
  24173. } else {
  24174. v[mk] = 0
  24175. }
  24176. continue
  24177. }
  24178. mv = uintptr(dd.DecodeUint(uintBitsize))
  24179. if v != nil {
  24180. v[mk] = mv
  24181. }
  24182. }
  24183. dd.ReadMapEnd()
  24184. return v, changed
  24185. }
  24186. func (d *Decoder) fastpathDecMapUint64IntR(f *codecFnInfo, rv reflect.Value) {
  24187. if rv.Kind() == reflect.Ptr {
  24188. vp := rv2i(rv).(*map[uint64]int)
  24189. if v, changed := fastpathTV.DecMapUint64IntV(*vp, true, d); changed {
  24190. *vp = v
  24191. }
  24192. return
  24193. }
  24194. fastpathTV.DecMapUint64IntV(rv2i(rv).(map[uint64]int), false, d)
  24195. }
  24196. func (f fastpathT) DecMapUint64IntX(vp *map[uint64]int, d *Decoder) {
  24197. if v, changed := f.DecMapUint64IntV(*vp, true, d); changed {
  24198. *vp = v
  24199. }
  24200. }
  24201. func (_ fastpathT) DecMapUint64IntV(v map[uint64]int, canChange bool,
  24202. d *Decoder) (_ map[uint64]int, changed bool) {
  24203. dd, esep := d.d, d.hh.hasElemSeparators()
  24204. containerLen := dd.ReadMapStart()
  24205. if canChange && v == nil {
  24206. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  24207. v = make(map[uint64]int, xlen)
  24208. changed = true
  24209. }
  24210. if containerLen == 0 {
  24211. dd.ReadMapEnd()
  24212. return v, changed
  24213. }
  24214. var mk uint64
  24215. var mv int
  24216. hasLen := containerLen > 0
  24217. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24218. if esep {
  24219. dd.ReadMapElemKey()
  24220. }
  24221. mk = dd.DecodeUint(64)
  24222. if esep {
  24223. dd.ReadMapElemValue()
  24224. }
  24225. if dd.TryDecodeAsNil() {
  24226. if d.h.DeleteOnNilMapValue {
  24227. delete(v, mk)
  24228. } else {
  24229. v[mk] = 0
  24230. }
  24231. continue
  24232. }
  24233. mv = int(dd.DecodeInt(intBitsize))
  24234. if v != nil {
  24235. v[mk] = mv
  24236. }
  24237. }
  24238. dd.ReadMapEnd()
  24239. return v, changed
  24240. }
  24241. func (d *Decoder) fastpathDecMapUint64Int8R(f *codecFnInfo, rv reflect.Value) {
  24242. if rv.Kind() == reflect.Ptr {
  24243. vp := rv2i(rv).(*map[uint64]int8)
  24244. if v, changed := fastpathTV.DecMapUint64Int8V(*vp, true, d); changed {
  24245. *vp = v
  24246. }
  24247. return
  24248. }
  24249. fastpathTV.DecMapUint64Int8V(rv2i(rv).(map[uint64]int8), false, d)
  24250. }
  24251. func (f fastpathT) DecMapUint64Int8X(vp *map[uint64]int8, d *Decoder) {
  24252. if v, changed := f.DecMapUint64Int8V(*vp, true, d); changed {
  24253. *vp = v
  24254. }
  24255. }
  24256. func (_ fastpathT) DecMapUint64Int8V(v map[uint64]int8, canChange bool,
  24257. d *Decoder) (_ map[uint64]int8, changed bool) {
  24258. dd, esep := d.d, d.hh.hasElemSeparators()
  24259. containerLen := dd.ReadMapStart()
  24260. if canChange && v == nil {
  24261. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  24262. v = make(map[uint64]int8, xlen)
  24263. changed = true
  24264. }
  24265. if containerLen == 0 {
  24266. dd.ReadMapEnd()
  24267. return v, changed
  24268. }
  24269. var mk uint64
  24270. var mv int8
  24271. hasLen := containerLen > 0
  24272. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24273. if esep {
  24274. dd.ReadMapElemKey()
  24275. }
  24276. mk = dd.DecodeUint(64)
  24277. if esep {
  24278. dd.ReadMapElemValue()
  24279. }
  24280. if dd.TryDecodeAsNil() {
  24281. if d.h.DeleteOnNilMapValue {
  24282. delete(v, mk)
  24283. } else {
  24284. v[mk] = 0
  24285. }
  24286. continue
  24287. }
  24288. mv = int8(dd.DecodeInt(8))
  24289. if v != nil {
  24290. v[mk] = mv
  24291. }
  24292. }
  24293. dd.ReadMapEnd()
  24294. return v, changed
  24295. }
  24296. func (d *Decoder) fastpathDecMapUint64Int16R(f *codecFnInfo, rv reflect.Value) {
  24297. if rv.Kind() == reflect.Ptr {
  24298. vp := rv2i(rv).(*map[uint64]int16)
  24299. if v, changed := fastpathTV.DecMapUint64Int16V(*vp, true, d); changed {
  24300. *vp = v
  24301. }
  24302. return
  24303. }
  24304. fastpathTV.DecMapUint64Int16V(rv2i(rv).(map[uint64]int16), false, d)
  24305. }
  24306. func (f fastpathT) DecMapUint64Int16X(vp *map[uint64]int16, d *Decoder) {
  24307. if v, changed := f.DecMapUint64Int16V(*vp, true, d); changed {
  24308. *vp = v
  24309. }
  24310. }
  24311. func (_ fastpathT) DecMapUint64Int16V(v map[uint64]int16, canChange bool,
  24312. d *Decoder) (_ map[uint64]int16, changed bool) {
  24313. dd, esep := d.d, d.hh.hasElemSeparators()
  24314. containerLen := dd.ReadMapStart()
  24315. if canChange && v == nil {
  24316. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  24317. v = make(map[uint64]int16, xlen)
  24318. changed = true
  24319. }
  24320. if containerLen == 0 {
  24321. dd.ReadMapEnd()
  24322. return v, changed
  24323. }
  24324. var mk uint64
  24325. var mv int16
  24326. hasLen := containerLen > 0
  24327. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24328. if esep {
  24329. dd.ReadMapElemKey()
  24330. }
  24331. mk = dd.DecodeUint(64)
  24332. if esep {
  24333. dd.ReadMapElemValue()
  24334. }
  24335. if dd.TryDecodeAsNil() {
  24336. if d.h.DeleteOnNilMapValue {
  24337. delete(v, mk)
  24338. } else {
  24339. v[mk] = 0
  24340. }
  24341. continue
  24342. }
  24343. mv = int16(dd.DecodeInt(16))
  24344. if v != nil {
  24345. v[mk] = mv
  24346. }
  24347. }
  24348. dd.ReadMapEnd()
  24349. return v, changed
  24350. }
  24351. func (d *Decoder) fastpathDecMapUint64Int32R(f *codecFnInfo, rv reflect.Value) {
  24352. if rv.Kind() == reflect.Ptr {
  24353. vp := rv2i(rv).(*map[uint64]int32)
  24354. if v, changed := fastpathTV.DecMapUint64Int32V(*vp, true, d); changed {
  24355. *vp = v
  24356. }
  24357. return
  24358. }
  24359. fastpathTV.DecMapUint64Int32V(rv2i(rv).(map[uint64]int32), false, d)
  24360. }
  24361. func (f fastpathT) DecMapUint64Int32X(vp *map[uint64]int32, d *Decoder) {
  24362. if v, changed := f.DecMapUint64Int32V(*vp, true, d); changed {
  24363. *vp = v
  24364. }
  24365. }
  24366. func (_ fastpathT) DecMapUint64Int32V(v map[uint64]int32, canChange bool,
  24367. d *Decoder) (_ map[uint64]int32, changed bool) {
  24368. dd, esep := d.d, d.hh.hasElemSeparators()
  24369. containerLen := dd.ReadMapStart()
  24370. if canChange && v == nil {
  24371. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  24372. v = make(map[uint64]int32, xlen)
  24373. changed = true
  24374. }
  24375. if containerLen == 0 {
  24376. dd.ReadMapEnd()
  24377. return v, changed
  24378. }
  24379. var mk uint64
  24380. var mv int32
  24381. hasLen := containerLen > 0
  24382. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24383. if esep {
  24384. dd.ReadMapElemKey()
  24385. }
  24386. mk = dd.DecodeUint(64)
  24387. if esep {
  24388. dd.ReadMapElemValue()
  24389. }
  24390. if dd.TryDecodeAsNil() {
  24391. if d.h.DeleteOnNilMapValue {
  24392. delete(v, mk)
  24393. } else {
  24394. v[mk] = 0
  24395. }
  24396. continue
  24397. }
  24398. mv = int32(dd.DecodeInt(32))
  24399. if v != nil {
  24400. v[mk] = mv
  24401. }
  24402. }
  24403. dd.ReadMapEnd()
  24404. return v, changed
  24405. }
  24406. func (d *Decoder) fastpathDecMapUint64Int64R(f *codecFnInfo, rv reflect.Value) {
  24407. if rv.Kind() == reflect.Ptr {
  24408. vp := rv2i(rv).(*map[uint64]int64)
  24409. if v, changed := fastpathTV.DecMapUint64Int64V(*vp, true, d); changed {
  24410. *vp = v
  24411. }
  24412. return
  24413. }
  24414. fastpathTV.DecMapUint64Int64V(rv2i(rv).(map[uint64]int64), false, d)
  24415. }
  24416. func (f fastpathT) DecMapUint64Int64X(vp *map[uint64]int64, d *Decoder) {
  24417. if v, changed := f.DecMapUint64Int64V(*vp, true, d); changed {
  24418. *vp = v
  24419. }
  24420. }
  24421. func (_ fastpathT) DecMapUint64Int64V(v map[uint64]int64, canChange bool,
  24422. d *Decoder) (_ map[uint64]int64, changed bool) {
  24423. dd, esep := d.d, d.hh.hasElemSeparators()
  24424. containerLen := dd.ReadMapStart()
  24425. if canChange && v == nil {
  24426. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  24427. v = make(map[uint64]int64, xlen)
  24428. changed = true
  24429. }
  24430. if containerLen == 0 {
  24431. dd.ReadMapEnd()
  24432. return v, changed
  24433. }
  24434. var mk uint64
  24435. var mv int64
  24436. hasLen := containerLen > 0
  24437. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24438. if esep {
  24439. dd.ReadMapElemKey()
  24440. }
  24441. mk = dd.DecodeUint(64)
  24442. if esep {
  24443. dd.ReadMapElemValue()
  24444. }
  24445. if dd.TryDecodeAsNil() {
  24446. if d.h.DeleteOnNilMapValue {
  24447. delete(v, mk)
  24448. } else {
  24449. v[mk] = 0
  24450. }
  24451. continue
  24452. }
  24453. mv = dd.DecodeInt(64)
  24454. if v != nil {
  24455. v[mk] = mv
  24456. }
  24457. }
  24458. dd.ReadMapEnd()
  24459. return v, changed
  24460. }
  24461. func (d *Decoder) fastpathDecMapUint64Float32R(f *codecFnInfo, rv reflect.Value) {
  24462. if rv.Kind() == reflect.Ptr {
  24463. vp := rv2i(rv).(*map[uint64]float32)
  24464. if v, changed := fastpathTV.DecMapUint64Float32V(*vp, true, d); changed {
  24465. *vp = v
  24466. }
  24467. return
  24468. }
  24469. fastpathTV.DecMapUint64Float32V(rv2i(rv).(map[uint64]float32), false, d)
  24470. }
  24471. func (f fastpathT) DecMapUint64Float32X(vp *map[uint64]float32, d *Decoder) {
  24472. if v, changed := f.DecMapUint64Float32V(*vp, true, d); changed {
  24473. *vp = v
  24474. }
  24475. }
  24476. func (_ fastpathT) DecMapUint64Float32V(v map[uint64]float32, canChange bool,
  24477. d *Decoder) (_ map[uint64]float32, changed bool) {
  24478. dd, esep := d.d, d.hh.hasElemSeparators()
  24479. containerLen := dd.ReadMapStart()
  24480. if canChange && v == nil {
  24481. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  24482. v = make(map[uint64]float32, xlen)
  24483. changed = true
  24484. }
  24485. if containerLen == 0 {
  24486. dd.ReadMapEnd()
  24487. return v, changed
  24488. }
  24489. var mk uint64
  24490. var mv float32
  24491. hasLen := containerLen > 0
  24492. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24493. if esep {
  24494. dd.ReadMapElemKey()
  24495. }
  24496. mk = dd.DecodeUint(64)
  24497. if esep {
  24498. dd.ReadMapElemValue()
  24499. }
  24500. if dd.TryDecodeAsNil() {
  24501. if d.h.DeleteOnNilMapValue {
  24502. delete(v, mk)
  24503. } else {
  24504. v[mk] = 0
  24505. }
  24506. continue
  24507. }
  24508. mv = float32(dd.DecodeFloat(true))
  24509. if v != nil {
  24510. v[mk] = mv
  24511. }
  24512. }
  24513. dd.ReadMapEnd()
  24514. return v, changed
  24515. }
  24516. func (d *Decoder) fastpathDecMapUint64Float64R(f *codecFnInfo, rv reflect.Value) {
  24517. if rv.Kind() == reflect.Ptr {
  24518. vp := rv2i(rv).(*map[uint64]float64)
  24519. if v, changed := fastpathTV.DecMapUint64Float64V(*vp, true, d); changed {
  24520. *vp = v
  24521. }
  24522. return
  24523. }
  24524. fastpathTV.DecMapUint64Float64V(rv2i(rv).(map[uint64]float64), false, d)
  24525. }
  24526. func (f fastpathT) DecMapUint64Float64X(vp *map[uint64]float64, d *Decoder) {
  24527. if v, changed := f.DecMapUint64Float64V(*vp, true, d); changed {
  24528. *vp = v
  24529. }
  24530. }
  24531. func (_ fastpathT) DecMapUint64Float64V(v map[uint64]float64, canChange bool,
  24532. d *Decoder) (_ map[uint64]float64, changed bool) {
  24533. dd, esep := d.d, d.hh.hasElemSeparators()
  24534. containerLen := dd.ReadMapStart()
  24535. if canChange && v == nil {
  24536. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  24537. v = make(map[uint64]float64, xlen)
  24538. changed = true
  24539. }
  24540. if containerLen == 0 {
  24541. dd.ReadMapEnd()
  24542. return v, changed
  24543. }
  24544. var mk uint64
  24545. var mv float64
  24546. hasLen := containerLen > 0
  24547. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24548. if esep {
  24549. dd.ReadMapElemKey()
  24550. }
  24551. mk = dd.DecodeUint(64)
  24552. if esep {
  24553. dd.ReadMapElemValue()
  24554. }
  24555. if dd.TryDecodeAsNil() {
  24556. if d.h.DeleteOnNilMapValue {
  24557. delete(v, mk)
  24558. } else {
  24559. v[mk] = 0
  24560. }
  24561. continue
  24562. }
  24563. mv = dd.DecodeFloat(false)
  24564. if v != nil {
  24565. v[mk] = mv
  24566. }
  24567. }
  24568. dd.ReadMapEnd()
  24569. return v, changed
  24570. }
  24571. func (d *Decoder) fastpathDecMapUint64BoolR(f *codecFnInfo, rv reflect.Value) {
  24572. if rv.Kind() == reflect.Ptr {
  24573. vp := rv2i(rv).(*map[uint64]bool)
  24574. if v, changed := fastpathTV.DecMapUint64BoolV(*vp, true, d); changed {
  24575. *vp = v
  24576. }
  24577. return
  24578. }
  24579. fastpathTV.DecMapUint64BoolV(rv2i(rv).(map[uint64]bool), false, d)
  24580. }
  24581. func (f fastpathT) DecMapUint64BoolX(vp *map[uint64]bool, d *Decoder) {
  24582. if v, changed := f.DecMapUint64BoolV(*vp, true, d); changed {
  24583. *vp = v
  24584. }
  24585. }
  24586. func (_ fastpathT) DecMapUint64BoolV(v map[uint64]bool, canChange bool,
  24587. d *Decoder) (_ map[uint64]bool, changed bool) {
  24588. dd, esep := d.d, d.hh.hasElemSeparators()
  24589. containerLen := dd.ReadMapStart()
  24590. if canChange && v == nil {
  24591. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  24592. v = make(map[uint64]bool, xlen)
  24593. changed = true
  24594. }
  24595. if containerLen == 0 {
  24596. dd.ReadMapEnd()
  24597. return v, changed
  24598. }
  24599. var mk uint64
  24600. var mv bool
  24601. hasLen := containerLen > 0
  24602. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24603. if esep {
  24604. dd.ReadMapElemKey()
  24605. }
  24606. mk = dd.DecodeUint(64)
  24607. if esep {
  24608. dd.ReadMapElemValue()
  24609. }
  24610. if dd.TryDecodeAsNil() {
  24611. if d.h.DeleteOnNilMapValue {
  24612. delete(v, mk)
  24613. } else {
  24614. v[mk] = false
  24615. }
  24616. continue
  24617. }
  24618. mv = dd.DecodeBool()
  24619. if v != nil {
  24620. v[mk] = mv
  24621. }
  24622. }
  24623. dd.ReadMapEnd()
  24624. return v, changed
  24625. }
  24626. func (d *Decoder) fastpathDecMapUintptrIntfR(f *codecFnInfo, rv reflect.Value) {
  24627. if rv.Kind() == reflect.Ptr {
  24628. vp := rv2i(rv).(*map[uintptr]interface{})
  24629. if v, changed := fastpathTV.DecMapUintptrIntfV(*vp, true, d); changed {
  24630. *vp = v
  24631. }
  24632. return
  24633. }
  24634. fastpathTV.DecMapUintptrIntfV(rv2i(rv).(map[uintptr]interface{}), false, d)
  24635. }
  24636. func (f fastpathT) DecMapUintptrIntfX(vp *map[uintptr]interface{}, d *Decoder) {
  24637. if v, changed := f.DecMapUintptrIntfV(*vp, true, d); changed {
  24638. *vp = v
  24639. }
  24640. }
  24641. func (_ fastpathT) DecMapUintptrIntfV(v map[uintptr]interface{}, canChange bool,
  24642. d *Decoder) (_ map[uintptr]interface{}, changed bool) {
  24643. dd, esep := d.d, d.hh.hasElemSeparators()
  24644. containerLen := dd.ReadMapStart()
  24645. if canChange && v == nil {
  24646. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  24647. v = make(map[uintptr]interface{}, xlen)
  24648. changed = true
  24649. }
  24650. if containerLen == 0 {
  24651. dd.ReadMapEnd()
  24652. return v, changed
  24653. }
  24654. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  24655. var mk uintptr
  24656. var mv interface{}
  24657. hasLen := containerLen > 0
  24658. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24659. if esep {
  24660. dd.ReadMapElemKey()
  24661. }
  24662. mk = uintptr(dd.DecodeUint(uintBitsize))
  24663. if esep {
  24664. dd.ReadMapElemValue()
  24665. }
  24666. if dd.TryDecodeAsNil() {
  24667. if d.h.DeleteOnNilMapValue {
  24668. delete(v, mk)
  24669. } else {
  24670. v[mk] = nil
  24671. }
  24672. continue
  24673. }
  24674. if mapGet {
  24675. mv = v[mk]
  24676. } else {
  24677. mv = nil
  24678. }
  24679. d.decode(&mv)
  24680. if v != nil {
  24681. v[mk] = mv
  24682. }
  24683. }
  24684. dd.ReadMapEnd()
  24685. return v, changed
  24686. }
  24687. func (d *Decoder) fastpathDecMapUintptrStringR(f *codecFnInfo, rv reflect.Value) {
  24688. if rv.Kind() == reflect.Ptr {
  24689. vp := rv2i(rv).(*map[uintptr]string)
  24690. if v, changed := fastpathTV.DecMapUintptrStringV(*vp, true, d); changed {
  24691. *vp = v
  24692. }
  24693. return
  24694. }
  24695. fastpathTV.DecMapUintptrStringV(rv2i(rv).(map[uintptr]string), false, d)
  24696. }
  24697. func (f fastpathT) DecMapUintptrStringX(vp *map[uintptr]string, d *Decoder) {
  24698. if v, changed := f.DecMapUintptrStringV(*vp, true, d); changed {
  24699. *vp = v
  24700. }
  24701. }
  24702. func (_ fastpathT) DecMapUintptrStringV(v map[uintptr]string, canChange bool,
  24703. d *Decoder) (_ map[uintptr]string, changed bool) {
  24704. dd, esep := d.d, d.hh.hasElemSeparators()
  24705. containerLen := dd.ReadMapStart()
  24706. if canChange && v == nil {
  24707. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  24708. v = make(map[uintptr]string, xlen)
  24709. changed = true
  24710. }
  24711. if containerLen == 0 {
  24712. dd.ReadMapEnd()
  24713. return v, changed
  24714. }
  24715. var mk uintptr
  24716. var mv string
  24717. hasLen := containerLen > 0
  24718. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24719. if esep {
  24720. dd.ReadMapElemKey()
  24721. }
  24722. mk = uintptr(dd.DecodeUint(uintBitsize))
  24723. if esep {
  24724. dd.ReadMapElemValue()
  24725. }
  24726. if dd.TryDecodeAsNil() {
  24727. if d.h.DeleteOnNilMapValue {
  24728. delete(v, mk)
  24729. } else {
  24730. v[mk] = ""
  24731. }
  24732. continue
  24733. }
  24734. mv = dd.DecodeString()
  24735. if v != nil {
  24736. v[mk] = mv
  24737. }
  24738. }
  24739. dd.ReadMapEnd()
  24740. return v, changed
  24741. }
  24742. func (d *Decoder) fastpathDecMapUintptrUintR(f *codecFnInfo, rv reflect.Value) {
  24743. if rv.Kind() == reflect.Ptr {
  24744. vp := rv2i(rv).(*map[uintptr]uint)
  24745. if v, changed := fastpathTV.DecMapUintptrUintV(*vp, true, d); changed {
  24746. *vp = v
  24747. }
  24748. return
  24749. }
  24750. fastpathTV.DecMapUintptrUintV(rv2i(rv).(map[uintptr]uint), false, d)
  24751. }
  24752. func (f fastpathT) DecMapUintptrUintX(vp *map[uintptr]uint, d *Decoder) {
  24753. if v, changed := f.DecMapUintptrUintV(*vp, true, d); changed {
  24754. *vp = v
  24755. }
  24756. }
  24757. func (_ fastpathT) DecMapUintptrUintV(v map[uintptr]uint, canChange bool,
  24758. d *Decoder) (_ map[uintptr]uint, changed bool) {
  24759. dd, esep := d.d, d.hh.hasElemSeparators()
  24760. containerLen := dd.ReadMapStart()
  24761. if canChange && v == nil {
  24762. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  24763. v = make(map[uintptr]uint, xlen)
  24764. changed = true
  24765. }
  24766. if containerLen == 0 {
  24767. dd.ReadMapEnd()
  24768. return v, changed
  24769. }
  24770. var mk uintptr
  24771. var mv uint
  24772. hasLen := containerLen > 0
  24773. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24774. if esep {
  24775. dd.ReadMapElemKey()
  24776. }
  24777. mk = uintptr(dd.DecodeUint(uintBitsize))
  24778. if esep {
  24779. dd.ReadMapElemValue()
  24780. }
  24781. if dd.TryDecodeAsNil() {
  24782. if d.h.DeleteOnNilMapValue {
  24783. delete(v, mk)
  24784. } else {
  24785. v[mk] = 0
  24786. }
  24787. continue
  24788. }
  24789. mv = uint(dd.DecodeUint(uintBitsize))
  24790. if v != nil {
  24791. v[mk] = mv
  24792. }
  24793. }
  24794. dd.ReadMapEnd()
  24795. return v, changed
  24796. }
  24797. func (d *Decoder) fastpathDecMapUintptrUint8R(f *codecFnInfo, rv reflect.Value) {
  24798. if rv.Kind() == reflect.Ptr {
  24799. vp := rv2i(rv).(*map[uintptr]uint8)
  24800. if v, changed := fastpathTV.DecMapUintptrUint8V(*vp, true, d); changed {
  24801. *vp = v
  24802. }
  24803. return
  24804. }
  24805. fastpathTV.DecMapUintptrUint8V(rv2i(rv).(map[uintptr]uint8), false, d)
  24806. }
  24807. func (f fastpathT) DecMapUintptrUint8X(vp *map[uintptr]uint8, d *Decoder) {
  24808. if v, changed := f.DecMapUintptrUint8V(*vp, true, d); changed {
  24809. *vp = v
  24810. }
  24811. }
  24812. func (_ fastpathT) DecMapUintptrUint8V(v map[uintptr]uint8, canChange bool,
  24813. d *Decoder) (_ map[uintptr]uint8, changed bool) {
  24814. dd, esep := d.d, d.hh.hasElemSeparators()
  24815. containerLen := dd.ReadMapStart()
  24816. if canChange && v == nil {
  24817. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  24818. v = make(map[uintptr]uint8, xlen)
  24819. changed = true
  24820. }
  24821. if containerLen == 0 {
  24822. dd.ReadMapEnd()
  24823. return v, changed
  24824. }
  24825. var mk uintptr
  24826. var mv uint8
  24827. hasLen := containerLen > 0
  24828. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24829. if esep {
  24830. dd.ReadMapElemKey()
  24831. }
  24832. mk = uintptr(dd.DecodeUint(uintBitsize))
  24833. if esep {
  24834. dd.ReadMapElemValue()
  24835. }
  24836. if dd.TryDecodeAsNil() {
  24837. if d.h.DeleteOnNilMapValue {
  24838. delete(v, mk)
  24839. } else {
  24840. v[mk] = 0
  24841. }
  24842. continue
  24843. }
  24844. mv = uint8(dd.DecodeUint(8))
  24845. if v != nil {
  24846. v[mk] = mv
  24847. }
  24848. }
  24849. dd.ReadMapEnd()
  24850. return v, changed
  24851. }
  24852. func (d *Decoder) fastpathDecMapUintptrUint16R(f *codecFnInfo, rv reflect.Value) {
  24853. if rv.Kind() == reflect.Ptr {
  24854. vp := rv2i(rv).(*map[uintptr]uint16)
  24855. if v, changed := fastpathTV.DecMapUintptrUint16V(*vp, true, d); changed {
  24856. *vp = v
  24857. }
  24858. return
  24859. }
  24860. fastpathTV.DecMapUintptrUint16V(rv2i(rv).(map[uintptr]uint16), false, d)
  24861. }
  24862. func (f fastpathT) DecMapUintptrUint16X(vp *map[uintptr]uint16, d *Decoder) {
  24863. if v, changed := f.DecMapUintptrUint16V(*vp, true, d); changed {
  24864. *vp = v
  24865. }
  24866. }
  24867. func (_ fastpathT) DecMapUintptrUint16V(v map[uintptr]uint16, canChange bool,
  24868. d *Decoder) (_ map[uintptr]uint16, changed bool) {
  24869. dd, esep := d.d, d.hh.hasElemSeparators()
  24870. containerLen := dd.ReadMapStart()
  24871. if canChange && v == nil {
  24872. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  24873. v = make(map[uintptr]uint16, xlen)
  24874. changed = true
  24875. }
  24876. if containerLen == 0 {
  24877. dd.ReadMapEnd()
  24878. return v, changed
  24879. }
  24880. var mk uintptr
  24881. var mv uint16
  24882. hasLen := containerLen > 0
  24883. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24884. if esep {
  24885. dd.ReadMapElemKey()
  24886. }
  24887. mk = uintptr(dd.DecodeUint(uintBitsize))
  24888. if esep {
  24889. dd.ReadMapElemValue()
  24890. }
  24891. if dd.TryDecodeAsNil() {
  24892. if d.h.DeleteOnNilMapValue {
  24893. delete(v, mk)
  24894. } else {
  24895. v[mk] = 0
  24896. }
  24897. continue
  24898. }
  24899. mv = uint16(dd.DecodeUint(16))
  24900. if v != nil {
  24901. v[mk] = mv
  24902. }
  24903. }
  24904. dd.ReadMapEnd()
  24905. return v, changed
  24906. }
  24907. func (d *Decoder) fastpathDecMapUintptrUint32R(f *codecFnInfo, rv reflect.Value) {
  24908. if rv.Kind() == reflect.Ptr {
  24909. vp := rv2i(rv).(*map[uintptr]uint32)
  24910. if v, changed := fastpathTV.DecMapUintptrUint32V(*vp, true, d); changed {
  24911. *vp = v
  24912. }
  24913. return
  24914. }
  24915. fastpathTV.DecMapUintptrUint32V(rv2i(rv).(map[uintptr]uint32), false, d)
  24916. }
  24917. func (f fastpathT) DecMapUintptrUint32X(vp *map[uintptr]uint32, d *Decoder) {
  24918. if v, changed := f.DecMapUintptrUint32V(*vp, true, d); changed {
  24919. *vp = v
  24920. }
  24921. }
  24922. func (_ fastpathT) DecMapUintptrUint32V(v map[uintptr]uint32, canChange bool,
  24923. d *Decoder) (_ map[uintptr]uint32, changed bool) {
  24924. dd, esep := d.d, d.hh.hasElemSeparators()
  24925. containerLen := dd.ReadMapStart()
  24926. if canChange && v == nil {
  24927. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  24928. v = make(map[uintptr]uint32, xlen)
  24929. changed = true
  24930. }
  24931. if containerLen == 0 {
  24932. dd.ReadMapEnd()
  24933. return v, changed
  24934. }
  24935. var mk uintptr
  24936. var mv uint32
  24937. hasLen := containerLen > 0
  24938. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24939. if esep {
  24940. dd.ReadMapElemKey()
  24941. }
  24942. mk = uintptr(dd.DecodeUint(uintBitsize))
  24943. if esep {
  24944. dd.ReadMapElemValue()
  24945. }
  24946. if dd.TryDecodeAsNil() {
  24947. if d.h.DeleteOnNilMapValue {
  24948. delete(v, mk)
  24949. } else {
  24950. v[mk] = 0
  24951. }
  24952. continue
  24953. }
  24954. mv = uint32(dd.DecodeUint(32))
  24955. if v != nil {
  24956. v[mk] = mv
  24957. }
  24958. }
  24959. dd.ReadMapEnd()
  24960. return v, changed
  24961. }
  24962. func (d *Decoder) fastpathDecMapUintptrUint64R(f *codecFnInfo, rv reflect.Value) {
  24963. if rv.Kind() == reflect.Ptr {
  24964. vp := rv2i(rv).(*map[uintptr]uint64)
  24965. if v, changed := fastpathTV.DecMapUintptrUint64V(*vp, true, d); changed {
  24966. *vp = v
  24967. }
  24968. return
  24969. }
  24970. fastpathTV.DecMapUintptrUint64V(rv2i(rv).(map[uintptr]uint64), false, d)
  24971. }
  24972. func (f fastpathT) DecMapUintptrUint64X(vp *map[uintptr]uint64, d *Decoder) {
  24973. if v, changed := f.DecMapUintptrUint64V(*vp, true, d); changed {
  24974. *vp = v
  24975. }
  24976. }
  24977. func (_ fastpathT) DecMapUintptrUint64V(v map[uintptr]uint64, canChange bool,
  24978. d *Decoder) (_ map[uintptr]uint64, changed bool) {
  24979. dd, esep := d.d, d.hh.hasElemSeparators()
  24980. containerLen := dd.ReadMapStart()
  24981. if canChange && v == nil {
  24982. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  24983. v = make(map[uintptr]uint64, xlen)
  24984. changed = true
  24985. }
  24986. if containerLen == 0 {
  24987. dd.ReadMapEnd()
  24988. return v, changed
  24989. }
  24990. var mk uintptr
  24991. var mv uint64
  24992. hasLen := containerLen > 0
  24993. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24994. if esep {
  24995. dd.ReadMapElemKey()
  24996. }
  24997. mk = uintptr(dd.DecodeUint(uintBitsize))
  24998. if esep {
  24999. dd.ReadMapElemValue()
  25000. }
  25001. if dd.TryDecodeAsNil() {
  25002. if d.h.DeleteOnNilMapValue {
  25003. delete(v, mk)
  25004. } else {
  25005. v[mk] = 0
  25006. }
  25007. continue
  25008. }
  25009. mv = dd.DecodeUint(64)
  25010. if v != nil {
  25011. v[mk] = mv
  25012. }
  25013. }
  25014. dd.ReadMapEnd()
  25015. return v, changed
  25016. }
  25017. func (d *Decoder) fastpathDecMapUintptrUintptrR(f *codecFnInfo, rv reflect.Value) {
  25018. if rv.Kind() == reflect.Ptr {
  25019. vp := rv2i(rv).(*map[uintptr]uintptr)
  25020. if v, changed := fastpathTV.DecMapUintptrUintptrV(*vp, true, d); changed {
  25021. *vp = v
  25022. }
  25023. return
  25024. }
  25025. fastpathTV.DecMapUintptrUintptrV(rv2i(rv).(map[uintptr]uintptr), false, d)
  25026. }
  25027. func (f fastpathT) DecMapUintptrUintptrX(vp *map[uintptr]uintptr, d *Decoder) {
  25028. if v, changed := f.DecMapUintptrUintptrV(*vp, true, d); changed {
  25029. *vp = v
  25030. }
  25031. }
  25032. func (_ fastpathT) DecMapUintptrUintptrV(v map[uintptr]uintptr, canChange bool,
  25033. d *Decoder) (_ map[uintptr]uintptr, changed bool) {
  25034. dd, esep := d.d, d.hh.hasElemSeparators()
  25035. containerLen := dd.ReadMapStart()
  25036. if canChange && v == nil {
  25037. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  25038. v = make(map[uintptr]uintptr, xlen)
  25039. changed = true
  25040. }
  25041. if containerLen == 0 {
  25042. dd.ReadMapEnd()
  25043. return v, changed
  25044. }
  25045. var mk uintptr
  25046. var mv uintptr
  25047. hasLen := containerLen > 0
  25048. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25049. if esep {
  25050. dd.ReadMapElemKey()
  25051. }
  25052. mk = uintptr(dd.DecodeUint(uintBitsize))
  25053. if esep {
  25054. dd.ReadMapElemValue()
  25055. }
  25056. if dd.TryDecodeAsNil() {
  25057. if d.h.DeleteOnNilMapValue {
  25058. delete(v, mk)
  25059. } else {
  25060. v[mk] = 0
  25061. }
  25062. continue
  25063. }
  25064. mv = uintptr(dd.DecodeUint(uintBitsize))
  25065. if v != nil {
  25066. v[mk] = mv
  25067. }
  25068. }
  25069. dd.ReadMapEnd()
  25070. return v, changed
  25071. }
  25072. func (d *Decoder) fastpathDecMapUintptrIntR(f *codecFnInfo, rv reflect.Value) {
  25073. if rv.Kind() == reflect.Ptr {
  25074. vp := rv2i(rv).(*map[uintptr]int)
  25075. if v, changed := fastpathTV.DecMapUintptrIntV(*vp, true, d); changed {
  25076. *vp = v
  25077. }
  25078. return
  25079. }
  25080. fastpathTV.DecMapUintptrIntV(rv2i(rv).(map[uintptr]int), false, d)
  25081. }
  25082. func (f fastpathT) DecMapUintptrIntX(vp *map[uintptr]int, d *Decoder) {
  25083. if v, changed := f.DecMapUintptrIntV(*vp, true, d); changed {
  25084. *vp = v
  25085. }
  25086. }
  25087. func (_ fastpathT) DecMapUintptrIntV(v map[uintptr]int, canChange bool,
  25088. d *Decoder) (_ map[uintptr]int, changed bool) {
  25089. dd, esep := d.d, d.hh.hasElemSeparators()
  25090. containerLen := dd.ReadMapStart()
  25091. if canChange && v == nil {
  25092. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  25093. v = make(map[uintptr]int, xlen)
  25094. changed = true
  25095. }
  25096. if containerLen == 0 {
  25097. dd.ReadMapEnd()
  25098. return v, changed
  25099. }
  25100. var mk uintptr
  25101. var mv int
  25102. hasLen := containerLen > 0
  25103. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25104. if esep {
  25105. dd.ReadMapElemKey()
  25106. }
  25107. mk = uintptr(dd.DecodeUint(uintBitsize))
  25108. if esep {
  25109. dd.ReadMapElemValue()
  25110. }
  25111. if dd.TryDecodeAsNil() {
  25112. if d.h.DeleteOnNilMapValue {
  25113. delete(v, mk)
  25114. } else {
  25115. v[mk] = 0
  25116. }
  25117. continue
  25118. }
  25119. mv = int(dd.DecodeInt(intBitsize))
  25120. if v != nil {
  25121. v[mk] = mv
  25122. }
  25123. }
  25124. dd.ReadMapEnd()
  25125. return v, changed
  25126. }
  25127. func (d *Decoder) fastpathDecMapUintptrInt8R(f *codecFnInfo, rv reflect.Value) {
  25128. if rv.Kind() == reflect.Ptr {
  25129. vp := rv2i(rv).(*map[uintptr]int8)
  25130. if v, changed := fastpathTV.DecMapUintptrInt8V(*vp, true, d); changed {
  25131. *vp = v
  25132. }
  25133. return
  25134. }
  25135. fastpathTV.DecMapUintptrInt8V(rv2i(rv).(map[uintptr]int8), false, d)
  25136. }
  25137. func (f fastpathT) DecMapUintptrInt8X(vp *map[uintptr]int8, d *Decoder) {
  25138. if v, changed := f.DecMapUintptrInt8V(*vp, true, d); changed {
  25139. *vp = v
  25140. }
  25141. }
  25142. func (_ fastpathT) DecMapUintptrInt8V(v map[uintptr]int8, canChange bool,
  25143. d *Decoder) (_ map[uintptr]int8, changed bool) {
  25144. dd, esep := d.d, d.hh.hasElemSeparators()
  25145. containerLen := dd.ReadMapStart()
  25146. if canChange && v == nil {
  25147. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  25148. v = make(map[uintptr]int8, xlen)
  25149. changed = true
  25150. }
  25151. if containerLen == 0 {
  25152. dd.ReadMapEnd()
  25153. return v, changed
  25154. }
  25155. var mk uintptr
  25156. var mv int8
  25157. hasLen := containerLen > 0
  25158. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25159. if esep {
  25160. dd.ReadMapElemKey()
  25161. }
  25162. mk = uintptr(dd.DecodeUint(uintBitsize))
  25163. if esep {
  25164. dd.ReadMapElemValue()
  25165. }
  25166. if dd.TryDecodeAsNil() {
  25167. if d.h.DeleteOnNilMapValue {
  25168. delete(v, mk)
  25169. } else {
  25170. v[mk] = 0
  25171. }
  25172. continue
  25173. }
  25174. mv = int8(dd.DecodeInt(8))
  25175. if v != nil {
  25176. v[mk] = mv
  25177. }
  25178. }
  25179. dd.ReadMapEnd()
  25180. return v, changed
  25181. }
  25182. func (d *Decoder) fastpathDecMapUintptrInt16R(f *codecFnInfo, rv reflect.Value) {
  25183. if rv.Kind() == reflect.Ptr {
  25184. vp := rv2i(rv).(*map[uintptr]int16)
  25185. if v, changed := fastpathTV.DecMapUintptrInt16V(*vp, true, d); changed {
  25186. *vp = v
  25187. }
  25188. return
  25189. }
  25190. fastpathTV.DecMapUintptrInt16V(rv2i(rv).(map[uintptr]int16), false, d)
  25191. }
  25192. func (f fastpathT) DecMapUintptrInt16X(vp *map[uintptr]int16, d *Decoder) {
  25193. if v, changed := f.DecMapUintptrInt16V(*vp, true, d); changed {
  25194. *vp = v
  25195. }
  25196. }
  25197. func (_ fastpathT) DecMapUintptrInt16V(v map[uintptr]int16, canChange bool,
  25198. d *Decoder) (_ map[uintptr]int16, changed bool) {
  25199. dd, esep := d.d, d.hh.hasElemSeparators()
  25200. containerLen := dd.ReadMapStart()
  25201. if canChange && v == nil {
  25202. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  25203. v = make(map[uintptr]int16, xlen)
  25204. changed = true
  25205. }
  25206. if containerLen == 0 {
  25207. dd.ReadMapEnd()
  25208. return v, changed
  25209. }
  25210. var mk uintptr
  25211. var mv int16
  25212. hasLen := containerLen > 0
  25213. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25214. if esep {
  25215. dd.ReadMapElemKey()
  25216. }
  25217. mk = uintptr(dd.DecodeUint(uintBitsize))
  25218. if esep {
  25219. dd.ReadMapElemValue()
  25220. }
  25221. if dd.TryDecodeAsNil() {
  25222. if d.h.DeleteOnNilMapValue {
  25223. delete(v, mk)
  25224. } else {
  25225. v[mk] = 0
  25226. }
  25227. continue
  25228. }
  25229. mv = int16(dd.DecodeInt(16))
  25230. if v != nil {
  25231. v[mk] = mv
  25232. }
  25233. }
  25234. dd.ReadMapEnd()
  25235. return v, changed
  25236. }
  25237. func (d *Decoder) fastpathDecMapUintptrInt32R(f *codecFnInfo, rv reflect.Value) {
  25238. if rv.Kind() == reflect.Ptr {
  25239. vp := rv2i(rv).(*map[uintptr]int32)
  25240. if v, changed := fastpathTV.DecMapUintptrInt32V(*vp, true, d); changed {
  25241. *vp = v
  25242. }
  25243. return
  25244. }
  25245. fastpathTV.DecMapUintptrInt32V(rv2i(rv).(map[uintptr]int32), false, d)
  25246. }
  25247. func (f fastpathT) DecMapUintptrInt32X(vp *map[uintptr]int32, d *Decoder) {
  25248. if v, changed := f.DecMapUintptrInt32V(*vp, true, d); changed {
  25249. *vp = v
  25250. }
  25251. }
  25252. func (_ fastpathT) DecMapUintptrInt32V(v map[uintptr]int32, canChange bool,
  25253. d *Decoder) (_ map[uintptr]int32, changed bool) {
  25254. dd, esep := d.d, d.hh.hasElemSeparators()
  25255. containerLen := dd.ReadMapStart()
  25256. if canChange && v == nil {
  25257. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  25258. v = make(map[uintptr]int32, xlen)
  25259. changed = true
  25260. }
  25261. if containerLen == 0 {
  25262. dd.ReadMapEnd()
  25263. return v, changed
  25264. }
  25265. var mk uintptr
  25266. var mv int32
  25267. hasLen := containerLen > 0
  25268. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25269. if esep {
  25270. dd.ReadMapElemKey()
  25271. }
  25272. mk = uintptr(dd.DecodeUint(uintBitsize))
  25273. if esep {
  25274. dd.ReadMapElemValue()
  25275. }
  25276. if dd.TryDecodeAsNil() {
  25277. if d.h.DeleteOnNilMapValue {
  25278. delete(v, mk)
  25279. } else {
  25280. v[mk] = 0
  25281. }
  25282. continue
  25283. }
  25284. mv = int32(dd.DecodeInt(32))
  25285. if v != nil {
  25286. v[mk] = mv
  25287. }
  25288. }
  25289. dd.ReadMapEnd()
  25290. return v, changed
  25291. }
  25292. func (d *Decoder) fastpathDecMapUintptrInt64R(f *codecFnInfo, rv reflect.Value) {
  25293. if rv.Kind() == reflect.Ptr {
  25294. vp := rv2i(rv).(*map[uintptr]int64)
  25295. if v, changed := fastpathTV.DecMapUintptrInt64V(*vp, true, d); changed {
  25296. *vp = v
  25297. }
  25298. return
  25299. }
  25300. fastpathTV.DecMapUintptrInt64V(rv2i(rv).(map[uintptr]int64), false, d)
  25301. }
  25302. func (f fastpathT) DecMapUintptrInt64X(vp *map[uintptr]int64, d *Decoder) {
  25303. if v, changed := f.DecMapUintptrInt64V(*vp, true, d); changed {
  25304. *vp = v
  25305. }
  25306. }
  25307. func (_ fastpathT) DecMapUintptrInt64V(v map[uintptr]int64, canChange bool,
  25308. d *Decoder) (_ map[uintptr]int64, changed bool) {
  25309. dd, esep := d.d, d.hh.hasElemSeparators()
  25310. containerLen := dd.ReadMapStart()
  25311. if canChange && v == nil {
  25312. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  25313. v = make(map[uintptr]int64, xlen)
  25314. changed = true
  25315. }
  25316. if containerLen == 0 {
  25317. dd.ReadMapEnd()
  25318. return v, changed
  25319. }
  25320. var mk uintptr
  25321. var mv int64
  25322. hasLen := containerLen > 0
  25323. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25324. if esep {
  25325. dd.ReadMapElemKey()
  25326. }
  25327. mk = uintptr(dd.DecodeUint(uintBitsize))
  25328. if esep {
  25329. dd.ReadMapElemValue()
  25330. }
  25331. if dd.TryDecodeAsNil() {
  25332. if d.h.DeleteOnNilMapValue {
  25333. delete(v, mk)
  25334. } else {
  25335. v[mk] = 0
  25336. }
  25337. continue
  25338. }
  25339. mv = dd.DecodeInt(64)
  25340. if v != nil {
  25341. v[mk] = mv
  25342. }
  25343. }
  25344. dd.ReadMapEnd()
  25345. return v, changed
  25346. }
  25347. func (d *Decoder) fastpathDecMapUintptrFloat32R(f *codecFnInfo, rv reflect.Value) {
  25348. if rv.Kind() == reflect.Ptr {
  25349. vp := rv2i(rv).(*map[uintptr]float32)
  25350. if v, changed := fastpathTV.DecMapUintptrFloat32V(*vp, true, d); changed {
  25351. *vp = v
  25352. }
  25353. return
  25354. }
  25355. fastpathTV.DecMapUintptrFloat32V(rv2i(rv).(map[uintptr]float32), false, d)
  25356. }
  25357. func (f fastpathT) DecMapUintptrFloat32X(vp *map[uintptr]float32, d *Decoder) {
  25358. if v, changed := f.DecMapUintptrFloat32V(*vp, true, d); changed {
  25359. *vp = v
  25360. }
  25361. }
  25362. func (_ fastpathT) DecMapUintptrFloat32V(v map[uintptr]float32, canChange bool,
  25363. d *Decoder) (_ map[uintptr]float32, changed bool) {
  25364. dd, esep := d.d, d.hh.hasElemSeparators()
  25365. containerLen := dd.ReadMapStart()
  25366. if canChange && v == nil {
  25367. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  25368. v = make(map[uintptr]float32, xlen)
  25369. changed = true
  25370. }
  25371. if containerLen == 0 {
  25372. dd.ReadMapEnd()
  25373. return v, changed
  25374. }
  25375. var mk uintptr
  25376. var mv float32
  25377. hasLen := containerLen > 0
  25378. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25379. if esep {
  25380. dd.ReadMapElemKey()
  25381. }
  25382. mk = uintptr(dd.DecodeUint(uintBitsize))
  25383. if esep {
  25384. dd.ReadMapElemValue()
  25385. }
  25386. if dd.TryDecodeAsNil() {
  25387. if d.h.DeleteOnNilMapValue {
  25388. delete(v, mk)
  25389. } else {
  25390. v[mk] = 0
  25391. }
  25392. continue
  25393. }
  25394. mv = float32(dd.DecodeFloat(true))
  25395. if v != nil {
  25396. v[mk] = mv
  25397. }
  25398. }
  25399. dd.ReadMapEnd()
  25400. return v, changed
  25401. }
  25402. func (d *Decoder) fastpathDecMapUintptrFloat64R(f *codecFnInfo, rv reflect.Value) {
  25403. if rv.Kind() == reflect.Ptr {
  25404. vp := rv2i(rv).(*map[uintptr]float64)
  25405. if v, changed := fastpathTV.DecMapUintptrFloat64V(*vp, true, d); changed {
  25406. *vp = v
  25407. }
  25408. return
  25409. }
  25410. fastpathTV.DecMapUintptrFloat64V(rv2i(rv).(map[uintptr]float64), false, d)
  25411. }
  25412. func (f fastpathT) DecMapUintptrFloat64X(vp *map[uintptr]float64, d *Decoder) {
  25413. if v, changed := f.DecMapUintptrFloat64V(*vp, true, d); changed {
  25414. *vp = v
  25415. }
  25416. }
  25417. func (_ fastpathT) DecMapUintptrFloat64V(v map[uintptr]float64, canChange bool,
  25418. d *Decoder) (_ map[uintptr]float64, changed bool) {
  25419. dd, esep := d.d, d.hh.hasElemSeparators()
  25420. containerLen := dd.ReadMapStart()
  25421. if canChange && v == nil {
  25422. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  25423. v = make(map[uintptr]float64, xlen)
  25424. changed = true
  25425. }
  25426. if containerLen == 0 {
  25427. dd.ReadMapEnd()
  25428. return v, changed
  25429. }
  25430. var mk uintptr
  25431. var mv float64
  25432. hasLen := containerLen > 0
  25433. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25434. if esep {
  25435. dd.ReadMapElemKey()
  25436. }
  25437. mk = uintptr(dd.DecodeUint(uintBitsize))
  25438. if esep {
  25439. dd.ReadMapElemValue()
  25440. }
  25441. if dd.TryDecodeAsNil() {
  25442. if d.h.DeleteOnNilMapValue {
  25443. delete(v, mk)
  25444. } else {
  25445. v[mk] = 0
  25446. }
  25447. continue
  25448. }
  25449. mv = dd.DecodeFloat(false)
  25450. if v != nil {
  25451. v[mk] = mv
  25452. }
  25453. }
  25454. dd.ReadMapEnd()
  25455. return v, changed
  25456. }
  25457. func (d *Decoder) fastpathDecMapUintptrBoolR(f *codecFnInfo, rv reflect.Value) {
  25458. if rv.Kind() == reflect.Ptr {
  25459. vp := rv2i(rv).(*map[uintptr]bool)
  25460. if v, changed := fastpathTV.DecMapUintptrBoolV(*vp, true, d); changed {
  25461. *vp = v
  25462. }
  25463. return
  25464. }
  25465. fastpathTV.DecMapUintptrBoolV(rv2i(rv).(map[uintptr]bool), false, d)
  25466. }
  25467. func (f fastpathT) DecMapUintptrBoolX(vp *map[uintptr]bool, d *Decoder) {
  25468. if v, changed := f.DecMapUintptrBoolV(*vp, true, d); changed {
  25469. *vp = v
  25470. }
  25471. }
  25472. func (_ fastpathT) DecMapUintptrBoolV(v map[uintptr]bool, canChange bool,
  25473. d *Decoder) (_ map[uintptr]bool, changed bool) {
  25474. dd, esep := d.d, d.hh.hasElemSeparators()
  25475. containerLen := dd.ReadMapStart()
  25476. if canChange && v == nil {
  25477. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  25478. v = make(map[uintptr]bool, xlen)
  25479. changed = true
  25480. }
  25481. if containerLen == 0 {
  25482. dd.ReadMapEnd()
  25483. return v, changed
  25484. }
  25485. var mk uintptr
  25486. var mv bool
  25487. hasLen := containerLen > 0
  25488. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25489. if esep {
  25490. dd.ReadMapElemKey()
  25491. }
  25492. mk = uintptr(dd.DecodeUint(uintBitsize))
  25493. if esep {
  25494. dd.ReadMapElemValue()
  25495. }
  25496. if dd.TryDecodeAsNil() {
  25497. if d.h.DeleteOnNilMapValue {
  25498. delete(v, mk)
  25499. } else {
  25500. v[mk] = false
  25501. }
  25502. continue
  25503. }
  25504. mv = dd.DecodeBool()
  25505. if v != nil {
  25506. v[mk] = mv
  25507. }
  25508. }
  25509. dd.ReadMapEnd()
  25510. return v, changed
  25511. }
  25512. func (d *Decoder) fastpathDecMapIntIntfR(f *codecFnInfo, rv reflect.Value) {
  25513. if rv.Kind() == reflect.Ptr {
  25514. vp := rv2i(rv).(*map[int]interface{})
  25515. if v, changed := fastpathTV.DecMapIntIntfV(*vp, true, d); changed {
  25516. *vp = v
  25517. }
  25518. return
  25519. }
  25520. fastpathTV.DecMapIntIntfV(rv2i(rv).(map[int]interface{}), false, d)
  25521. }
  25522. func (f fastpathT) DecMapIntIntfX(vp *map[int]interface{}, d *Decoder) {
  25523. if v, changed := f.DecMapIntIntfV(*vp, true, d); changed {
  25524. *vp = v
  25525. }
  25526. }
  25527. func (_ fastpathT) DecMapIntIntfV(v map[int]interface{}, canChange bool,
  25528. d *Decoder) (_ map[int]interface{}, changed bool) {
  25529. dd, esep := d.d, d.hh.hasElemSeparators()
  25530. containerLen := dd.ReadMapStart()
  25531. if canChange && v == nil {
  25532. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  25533. v = make(map[int]interface{}, xlen)
  25534. changed = true
  25535. }
  25536. if containerLen == 0 {
  25537. dd.ReadMapEnd()
  25538. return v, changed
  25539. }
  25540. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  25541. var mk int
  25542. var mv interface{}
  25543. hasLen := containerLen > 0
  25544. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25545. if esep {
  25546. dd.ReadMapElemKey()
  25547. }
  25548. mk = int(dd.DecodeInt(intBitsize))
  25549. if esep {
  25550. dd.ReadMapElemValue()
  25551. }
  25552. if dd.TryDecodeAsNil() {
  25553. if d.h.DeleteOnNilMapValue {
  25554. delete(v, mk)
  25555. } else {
  25556. v[mk] = nil
  25557. }
  25558. continue
  25559. }
  25560. if mapGet {
  25561. mv = v[mk]
  25562. } else {
  25563. mv = nil
  25564. }
  25565. d.decode(&mv)
  25566. if v != nil {
  25567. v[mk] = mv
  25568. }
  25569. }
  25570. dd.ReadMapEnd()
  25571. return v, changed
  25572. }
  25573. func (d *Decoder) fastpathDecMapIntStringR(f *codecFnInfo, rv reflect.Value) {
  25574. if rv.Kind() == reflect.Ptr {
  25575. vp := rv2i(rv).(*map[int]string)
  25576. if v, changed := fastpathTV.DecMapIntStringV(*vp, true, d); changed {
  25577. *vp = v
  25578. }
  25579. return
  25580. }
  25581. fastpathTV.DecMapIntStringV(rv2i(rv).(map[int]string), false, d)
  25582. }
  25583. func (f fastpathT) DecMapIntStringX(vp *map[int]string, d *Decoder) {
  25584. if v, changed := f.DecMapIntStringV(*vp, true, d); changed {
  25585. *vp = v
  25586. }
  25587. }
  25588. func (_ fastpathT) DecMapIntStringV(v map[int]string, canChange bool,
  25589. d *Decoder) (_ map[int]string, changed bool) {
  25590. dd, esep := d.d, d.hh.hasElemSeparators()
  25591. containerLen := dd.ReadMapStart()
  25592. if canChange && v == nil {
  25593. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  25594. v = make(map[int]string, xlen)
  25595. changed = true
  25596. }
  25597. if containerLen == 0 {
  25598. dd.ReadMapEnd()
  25599. return v, changed
  25600. }
  25601. var mk int
  25602. var mv string
  25603. hasLen := containerLen > 0
  25604. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25605. if esep {
  25606. dd.ReadMapElemKey()
  25607. }
  25608. mk = int(dd.DecodeInt(intBitsize))
  25609. if esep {
  25610. dd.ReadMapElemValue()
  25611. }
  25612. if dd.TryDecodeAsNil() {
  25613. if d.h.DeleteOnNilMapValue {
  25614. delete(v, mk)
  25615. } else {
  25616. v[mk] = ""
  25617. }
  25618. continue
  25619. }
  25620. mv = dd.DecodeString()
  25621. if v != nil {
  25622. v[mk] = mv
  25623. }
  25624. }
  25625. dd.ReadMapEnd()
  25626. return v, changed
  25627. }
  25628. func (d *Decoder) fastpathDecMapIntUintR(f *codecFnInfo, rv reflect.Value) {
  25629. if rv.Kind() == reflect.Ptr {
  25630. vp := rv2i(rv).(*map[int]uint)
  25631. if v, changed := fastpathTV.DecMapIntUintV(*vp, true, d); changed {
  25632. *vp = v
  25633. }
  25634. return
  25635. }
  25636. fastpathTV.DecMapIntUintV(rv2i(rv).(map[int]uint), false, d)
  25637. }
  25638. func (f fastpathT) DecMapIntUintX(vp *map[int]uint, d *Decoder) {
  25639. if v, changed := f.DecMapIntUintV(*vp, true, d); changed {
  25640. *vp = v
  25641. }
  25642. }
  25643. func (_ fastpathT) DecMapIntUintV(v map[int]uint, canChange bool,
  25644. d *Decoder) (_ map[int]uint, changed bool) {
  25645. dd, esep := d.d, d.hh.hasElemSeparators()
  25646. containerLen := dd.ReadMapStart()
  25647. if canChange && v == nil {
  25648. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  25649. v = make(map[int]uint, xlen)
  25650. changed = true
  25651. }
  25652. if containerLen == 0 {
  25653. dd.ReadMapEnd()
  25654. return v, changed
  25655. }
  25656. var mk int
  25657. var mv uint
  25658. hasLen := containerLen > 0
  25659. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25660. if esep {
  25661. dd.ReadMapElemKey()
  25662. }
  25663. mk = int(dd.DecodeInt(intBitsize))
  25664. if esep {
  25665. dd.ReadMapElemValue()
  25666. }
  25667. if dd.TryDecodeAsNil() {
  25668. if d.h.DeleteOnNilMapValue {
  25669. delete(v, mk)
  25670. } else {
  25671. v[mk] = 0
  25672. }
  25673. continue
  25674. }
  25675. mv = uint(dd.DecodeUint(uintBitsize))
  25676. if v != nil {
  25677. v[mk] = mv
  25678. }
  25679. }
  25680. dd.ReadMapEnd()
  25681. return v, changed
  25682. }
  25683. func (d *Decoder) fastpathDecMapIntUint8R(f *codecFnInfo, rv reflect.Value) {
  25684. if rv.Kind() == reflect.Ptr {
  25685. vp := rv2i(rv).(*map[int]uint8)
  25686. if v, changed := fastpathTV.DecMapIntUint8V(*vp, true, d); changed {
  25687. *vp = v
  25688. }
  25689. return
  25690. }
  25691. fastpathTV.DecMapIntUint8V(rv2i(rv).(map[int]uint8), false, d)
  25692. }
  25693. func (f fastpathT) DecMapIntUint8X(vp *map[int]uint8, d *Decoder) {
  25694. if v, changed := f.DecMapIntUint8V(*vp, true, d); changed {
  25695. *vp = v
  25696. }
  25697. }
  25698. func (_ fastpathT) DecMapIntUint8V(v map[int]uint8, canChange bool,
  25699. d *Decoder) (_ map[int]uint8, changed bool) {
  25700. dd, esep := d.d, d.hh.hasElemSeparators()
  25701. containerLen := dd.ReadMapStart()
  25702. if canChange && v == nil {
  25703. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  25704. v = make(map[int]uint8, xlen)
  25705. changed = true
  25706. }
  25707. if containerLen == 0 {
  25708. dd.ReadMapEnd()
  25709. return v, changed
  25710. }
  25711. var mk int
  25712. var mv uint8
  25713. hasLen := containerLen > 0
  25714. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25715. if esep {
  25716. dd.ReadMapElemKey()
  25717. }
  25718. mk = int(dd.DecodeInt(intBitsize))
  25719. if esep {
  25720. dd.ReadMapElemValue()
  25721. }
  25722. if dd.TryDecodeAsNil() {
  25723. if d.h.DeleteOnNilMapValue {
  25724. delete(v, mk)
  25725. } else {
  25726. v[mk] = 0
  25727. }
  25728. continue
  25729. }
  25730. mv = uint8(dd.DecodeUint(8))
  25731. if v != nil {
  25732. v[mk] = mv
  25733. }
  25734. }
  25735. dd.ReadMapEnd()
  25736. return v, changed
  25737. }
  25738. func (d *Decoder) fastpathDecMapIntUint16R(f *codecFnInfo, rv reflect.Value) {
  25739. if rv.Kind() == reflect.Ptr {
  25740. vp := rv2i(rv).(*map[int]uint16)
  25741. if v, changed := fastpathTV.DecMapIntUint16V(*vp, true, d); changed {
  25742. *vp = v
  25743. }
  25744. return
  25745. }
  25746. fastpathTV.DecMapIntUint16V(rv2i(rv).(map[int]uint16), false, d)
  25747. }
  25748. func (f fastpathT) DecMapIntUint16X(vp *map[int]uint16, d *Decoder) {
  25749. if v, changed := f.DecMapIntUint16V(*vp, true, d); changed {
  25750. *vp = v
  25751. }
  25752. }
  25753. func (_ fastpathT) DecMapIntUint16V(v map[int]uint16, canChange bool,
  25754. d *Decoder) (_ map[int]uint16, changed bool) {
  25755. dd, esep := d.d, d.hh.hasElemSeparators()
  25756. containerLen := dd.ReadMapStart()
  25757. if canChange && v == nil {
  25758. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  25759. v = make(map[int]uint16, xlen)
  25760. changed = true
  25761. }
  25762. if containerLen == 0 {
  25763. dd.ReadMapEnd()
  25764. return v, changed
  25765. }
  25766. var mk int
  25767. var mv uint16
  25768. hasLen := containerLen > 0
  25769. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25770. if esep {
  25771. dd.ReadMapElemKey()
  25772. }
  25773. mk = int(dd.DecodeInt(intBitsize))
  25774. if esep {
  25775. dd.ReadMapElemValue()
  25776. }
  25777. if dd.TryDecodeAsNil() {
  25778. if d.h.DeleteOnNilMapValue {
  25779. delete(v, mk)
  25780. } else {
  25781. v[mk] = 0
  25782. }
  25783. continue
  25784. }
  25785. mv = uint16(dd.DecodeUint(16))
  25786. if v != nil {
  25787. v[mk] = mv
  25788. }
  25789. }
  25790. dd.ReadMapEnd()
  25791. return v, changed
  25792. }
  25793. func (d *Decoder) fastpathDecMapIntUint32R(f *codecFnInfo, rv reflect.Value) {
  25794. if rv.Kind() == reflect.Ptr {
  25795. vp := rv2i(rv).(*map[int]uint32)
  25796. if v, changed := fastpathTV.DecMapIntUint32V(*vp, true, d); changed {
  25797. *vp = v
  25798. }
  25799. return
  25800. }
  25801. fastpathTV.DecMapIntUint32V(rv2i(rv).(map[int]uint32), false, d)
  25802. }
  25803. func (f fastpathT) DecMapIntUint32X(vp *map[int]uint32, d *Decoder) {
  25804. if v, changed := f.DecMapIntUint32V(*vp, true, d); changed {
  25805. *vp = v
  25806. }
  25807. }
  25808. func (_ fastpathT) DecMapIntUint32V(v map[int]uint32, canChange bool,
  25809. d *Decoder) (_ map[int]uint32, changed bool) {
  25810. dd, esep := d.d, d.hh.hasElemSeparators()
  25811. containerLen := dd.ReadMapStart()
  25812. if canChange && v == nil {
  25813. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  25814. v = make(map[int]uint32, xlen)
  25815. changed = true
  25816. }
  25817. if containerLen == 0 {
  25818. dd.ReadMapEnd()
  25819. return v, changed
  25820. }
  25821. var mk int
  25822. var mv uint32
  25823. hasLen := containerLen > 0
  25824. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25825. if esep {
  25826. dd.ReadMapElemKey()
  25827. }
  25828. mk = int(dd.DecodeInt(intBitsize))
  25829. if esep {
  25830. dd.ReadMapElemValue()
  25831. }
  25832. if dd.TryDecodeAsNil() {
  25833. if d.h.DeleteOnNilMapValue {
  25834. delete(v, mk)
  25835. } else {
  25836. v[mk] = 0
  25837. }
  25838. continue
  25839. }
  25840. mv = uint32(dd.DecodeUint(32))
  25841. if v != nil {
  25842. v[mk] = mv
  25843. }
  25844. }
  25845. dd.ReadMapEnd()
  25846. return v, changed
  25847. }
  25848. func (d *Decoder) fastpathDecMapIntUint64R(f *codecFnInfo, rv reflect.Value) {
  25849. if rv.Kind() == reflect.Ptr {
  25850. vp := rv2i(rv).(*map[int]uint64)
  25851. if v, changed := fastpathTV.DecMapIntUint64V(*vp, true, d); changed {
  25852. *vp = v
  25853. }
  25854. return
  25855. }
  25856. fastpathTV.DecMapIntUint64V(rv2i(rv).(map[int]uint64), false, d)
  25857. }
  25858. func (f fastpathT) DecMapIntUint64X(vp *map[int]uint64, d *Decoder) {
  25859. if v, changed := f.DecMapIntUint64V(*vp, true, d); changed {
  25860. *vp = v
  25861. }
  25862. }
  25863. func (_ fastpathT) DecMapIntUint64V(v map[int]uint64, canChange bool,
  25864. d *Decoder) (_ map[int]uint64, changed bool) {
  25865. dd, esep := d.d, d.hh.hasElemSeparators()
  25866. containerLen := dd.ReadMapStart()
  25867. if canChange && v == nil {
  25868. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  25869. v = make(map[int]uint64, xlen)
  25870. changed = true
  25871. }
  25872. if containerLen == 0 {
  25873. dd.ReadMapEnd()
  25874. return v, changed
  25875. }
  25876. var mk int
  25877. var mv uint64
  25878. hasLen := containerLen > 0
  25879. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25880. if esep {
  25881. dd.ReadMapElemKey()
  25882. }
  25883. mk = int(dd.DecodeInt(intBitsize))
  25884. if esep {
  25885. dd.ReadMapElemValue()
  25886. }
  25887. if dd.TryDecodeAsNil() {
  25888. if d.h.DeleteOnNilMapValue {
  25889. delete(v, mk)
  25890. } else {
  25891. v[mk] = 0
  25892. }
  25893. continue
  25894. }
  25895. mv = dd.DecodeUint(64)
  25896. if v != nil {
  25897. v[mk] = mv
  25898. }
  25899. }
  25900. dd.ReadMapEnd()
  25901. return v, changed
  25902. }
  25903. func (d *Decoder) fastpathDecMapIntUintptrR(f *codecFnInfo, rv reflect.Value) {
  25904. if rv.Kind() == reflect.Ptr {
  25905. vp := rv2i(rv).(*map[int]uintptr)
  25906. if v, changed := fastpathTV.DecMapIntUintptrV(*vp, true, d); changed {
  25907. *vp = v
  25908. }
  25909. return
  25910. }
  25911. fastpathTV.DecMapIntUintptrV(rv2i(rv).(map[int]uintptr), false, d)
  25912. }
  25913. func (f fastpathT) DecMapIntUintptrX(vp *map[int]uintptr, d *Decoder) {
  25914. if v, changed := f.DecMapIntUintptrV(*vp, true, d); changed {
  25915. *vp = v
  25916. }
  25917. }
  25918. func (_ fastpathT) DecMapIntUintptrV(v map[int]uintptr, canChange bool,
  25919. d *Decoder) (_ map[int]uintptr, changed bool) {
  25920. dd, esep := d.d, d.hh.hasElemSeparators()
  25921. containerLen := dd.ReadMapStart()
  25922. if canChange && v == nil {
  25923. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  25924. v = make(map[int]uintptr, xlen)
  25925. changed = true
  25926. }
  25927. if containerLen == 0 {
  25928. dd.ReadMapEnd()
  25929. return v, changed
  25930. }
  25931. var mk int
  25932. var mv uintptr
  25933. hasLen := containerLen > 0
  25934. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25935. if esep {
  25936. dd.ReadMapElemKey()
  25937. }
  25938. mk = int(dd.DecodeInt(intBitsize))
  25939. if esep {
  25940. dd.ReadMapElemValue()
  25941. }
  25942. if dd.TryDecodeAsNil() {
  25943. if d.h.DeleteOnNilMapValue {
  25944. delete(v, mk)
  25945. } else {
  25946. v[mk] = 0
  25947. }
  25948. continue
  25949. }
  25950. mv = uintptr(dd.DecodeUint(uintBitsize))
  25951. if v != nil {
  25952. v[mk] = mv
  25953. }
  25954. }
  25955. dd.ReadMapEnd()
  25956. return v, changed
  25957. }
  25958. func (d *Decoder) fastpathDecMapIntIntR(f *codecFnInfo, rv reflect.Value) {
  25959. if rv.Kind() == reflect.Ptr {
  25960. vp := rv2i(rv).(*map[int]int)
  25961. if v, changed := fastpathTV.DecMapIntIntV(*vp, true, d); changed {
  25962. *vp = v
  25963. }
  25964. return
  25965. }
  25966. fastpathTV.DecMapIntIntV(rv2i(rv).(map[int]int), false, d)
  25967. }
  25968. func (f fastpathT) DecMapIntIntX(vp *map[int]int, d *Decoder) {
  25969. if v, changed := f.DecMapIntIntV(*vp, true, d); changed {
  25970. *vp = v
  25971. }
  25972. }
  25973. func (_ fastpathT) DecMapIntIntV(v map[int]int, canChange bool,
  25974. d *Decoder) (_ map[int]int, changed bool) {
  25975. dd, esep := d.d, d.hh.hasElemSeparators()
  25976. containerLen := dd.ReadMapStart()
  25977. if canChange && v == nil {
  25978. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  25979. v = make(map[int]int, xlen)
  25980. changed = true
  25981. }
  25982. if containerLen == 0 {
  25983. dd.ReadMapEnd()
  25984. return v, changed
  25985. }
  25986. var mk int
  25987. var mv int
  25988. hasLen := containerLen > 0
  25989. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25990. if esep {
  25991. dd.ReadMapElemKey()
  25992. }
  25993. mk = int(dd.DecodeInt(intBitsize))
  25994. if esep {
  25995. dd.ReadMapElemValue()
  25996. }
  25997. if dd.TryDecodeAsNil() {
  25998. if d.h.DeleteOnNilMapValue {
  25999. delete(v, mk)
  26000. } else {
  26001. v[mk] = 0
  26002. }
  26003. continue
  26004. }
  26005. mv = int(dd.DecodeInt(intBitsize))
  26006. if v != nil {
  26007. v[mk] = mv
  26008. }
  26009. }
  26010. dd.ReadMapEnd()
  26011. return v, changed
  26012. }
  26013. func (d *Decoder) fastpathDecMapIntInt8R(f *codecFnInfo, rv reflect.Value) {
  26014. if rv.Kind() == reflect.Ptr {
  26015. vp := rv2i(rv).(*map[int]int8)
  26016. if v, changed := fastpathTV.DecMapIntInt8V(*vp, true, d); changed {
  26017. *vp = v
  26018. }
  26019. return
  26020. }
  26021. fastpathTV.DecMapIntInt8V(rv2i(rv).(map[int]int8), false, d)
  26022. }
  26023. func (f fastpathT) DecMapIntInt8X(vp *map[int]int8, d *Decoder) {
  26024. if v, changed := f.DecMapIntInt8V(*vp, true, d); changed {
  26025. *vp = v
  26026. }
  26027. }
  26028. func (_ fastpathT) DecMapIntInt8V(v map[int]int8, canChange bool,
  26029. d *Decoder) (_ map[int]int8, changed bool) {
  26030. dd, esep := d.d, d.hh.hasElemSeparators()
  26031. containerLen := dd.ReadMapStart()
  26032. if canChange && v == nil {
  26033. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  26034. v = make(map[int]int8, xlen)
  26035. changed = true
  26036. }
  26037. if containerLen == 0 {
  26038. dd.ReadMapEnd()
  26039. return v, changed
  26040. }
  26041. var mk int
  26042. var mv int8
  26043. hasLen := containerLen > 0
  26044. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26045. if esep {
  26046. dd.ReadMapElemKey()
  26047. }
  26048. mk = int(dd.DecodeInt(intBitsize))
  26049. if esep {
  26050. dd.ReadMapElemValue()
  26051. }
  26052. if dd.TryDecodeAsNil() {
  26053. if d.h.DeleteOnNilMapValue {
  26054. delete(v, mk)
  26055. } else {
  26056. v[mk] = 0
  26057. }
  26058. continue
  26059. }
  26060. mv = int8(dd.DecodeInt(8))
  26061. if v != nil {
  26062. v[mk] = mv
  26063. }
  26064. }
  26065. dd.ReadMapEnd()
  26066. return v, changed
  26067. }
  26068. func (d *Decoder) fastpathDecMapIntInt16R(f *codecFnInfo, rv reflect.Value) {
  26069. if rv.Kind() == reflect.Ptr {
  26070. vp := rv2i(rv).(*map[int]int16)
  26071. if v, changed := fastpathTV.DecMapIntInt16V(*vp, true, d); changed {
  26072. *vp = v
  26073. }
  26074. return
  26075. }
  26076. fastpathTV.DecMapIntInt16V(rv2i(rv).(map[int]int16), false, d)
  26077. }
  26078. func (f fastpathT) DecMapIntInt16X(vp *map[int]int16, d *Decoder) {
  26079. if v, changed := f.DecMapIntInt16V(*vp, true, d); changed {
  26080. *vp = v
  26081. }
  26082. }
  26083. func (_ fastpathT) DecMapIntInt16V(v map[int]int16, canChange bool,
  26084. d *Decoder) (_ map[int]int16, changed bool) {
  26085. dd, esep := d.d, d.hh.hasElemSeparators()
  26086. containerLen := dd.ReadMapStart()
  26087. if canChange && v == nil {
  26088. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  26089. v = make(map[int]int16, xlen)
  26090. changed = true
  26091. }
  26092. if containerLen == 0 {
  26093. dd.ReadMapEnd()
  26094. return v, changed
  26095. }
  26096. var mk int
  26097. var mv int16
  26098. hasLen := containerLen > 0
  26099. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26100. if esep {
  26101. dd.ReadMapElemKey()
  26102. }
  26103. mk = int(dd.DecodeInt(intBitsize))
  26104. if esep {
  26105. dd.ReadMapElemValue()
  26106. }
  26107. if dd.TryDecodeAsNil() {
  26108. if d.h.DeleteOnNilMapValue {
  26109. delete(v, mk)
  26110. } else {
  26111. v[mk] = 0
  26112. }
  26113. continue
  26114. }
  26115. mv = int16(dd.DecodeInt(16))
  26116. if v != nil {
  26117. v[mk] = mv
  26118. }
  26119. }
  26120. dd.ReadMapEnd()
  26121. return v, changed
  26122. }
  26123. func (d *Decoder) fastpathDecMapIntInt32R(f *codecFnInfo, rv reflect.Value) {
  26124. if rv.Kind() == reflect.Ptr {
  26125. vp := rv2i(rv).(*map[int]int32)
  26126. if v, changed := fastpathTV.DecMapIntInt32V(*vp, true, d); changed {
  26127. *vp = v
  26128. }
  26129. return
  26130. }
  26131. fastpathTV.DecMapIntInt32V(rv2i(rv).(map[int]int32), false, d)
  26132. }
  26133. func (f fastpathT) DecMapIntInt32X(vp *map[int]int32, d *Decoder) {
  26134. if v, changed := f.DecMapIntInt32V(*vp, true, d); changed {
  26135. *vp = v
  26136. }
  26137. }
  26138. func (_ fastpathT) DecMapIntInt32V(v map[int]int32, canChange bool,
  26139. d *Decoder) (_ map[int]int32, changed bool) {
  26140. dd, esep := d.d, d.hh.hasElemSeparators()
  26141. containerLen := dd.ReadMapStart()
  26142. if canChange && v == nil {
  26143. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  26144. v = make(map[int]int32, xlen)
  26145. changed = true
  26146. }
  26147. if containerLen == 0 {
  26148. dd.ReadMapEnd()
  26149. return v, changed
  26150. }
  26151. var mk int
  26152. var mv int32
  26153. hasLen := containerLen > 0
  26154. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26155. if esep {
  26156. dd.ReadMapElemKey()
  26157. }
  26158. mk = int(dd.DecodeInt(intBitsize))
  26159. if esep {
  26160. dd.ReadMapElemValue()
  26161. }
  26162. if dd.TryDecodeAsNil() {
  26163. if d.h.DeleteOnNilMapValue {
  26164. delete(v, mk)
  26165. } else {
  26166. v[mk] = 0
  26167. }
  26168. continue
  26169. }
  26170. mv = int32(dd.DecodeInt(32))
  26171. if v != nil {
  26172. v[mk] = mv
  26173. }
  26174. }
  26175. dd.ReadMapEnd()
  26176. return v, changed
  26177. }
  26178. func (d *Decoder) fastpathDecMapIntInt64R(f *codecFnInfo, rv reflect.Value) {
  26179. if rv.Kind() == reflect.Ptr {
  26180. vp := rv2i(rv).(*map[int]int64)
  26181. if v, changed := fastpathTV.DecMapIntInt64V(*vp, true, d); changed {
  26182. *vp = v
  26183. }
  26184. return
  26185. }
  26186. fastpathTV.DecMapIntInt64V(rv2i(rv).(map[int]int64), false, d)
  26187. }
  26188. func (f fastpathT) DecMapIntInt64X(vp *map[int]int64, d *Decoder) {
  26189. if v, changed := f.DecMapIntInt64V(*vp, true, d); changed {
  26190. *vp = v
  26191. }
  26192. }
  26193. func (_ fastpathT) DecMapIntInt64V(v map[int]int64, canChange bool,
  26194. d *Decoder) (_ map[int]int64, changed bool) {
  26195. dd, esep := d.d, d.hh.hasElemSeparators()
  26196. containerLen := dd.ReadMapStart()
  26197. if canChange && v == nil {
  26198. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  26199. v = make(map[int]int64, xlen)
  26200. changed = true
  26201. }
  26202. if containerLen == 0 {
  26203. dd.ReadMapEnd()
  26204. return v, changed
  26205. }
  26206. var mk int
  26207. var mv int64
  26208. hasLen := containerLen > 0
  26209. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26210. if esep {
  26211. dd.ReadMapElemKey()
  26212. }
  26213. mk = int(dd.DecodeInt(intBitsize))
  26214. if esep {
  26215. dd.ReadMapElemValue()
  26216. }
  26217. if dd.TryDecodeAsNil() {
  26218. if d.h.DeleteOnNilMapValue {
  26219. delete(v, mk)
  26220. } else {
  26221. v[mk] = 0
  26222. }
  26223. continue
  26224. }
  26225. mv = dd.DecodeInt(64)
  26226. if v != nil {
  26227. v[mk] = mv
  26228. }
  26229. }
  26230. dd.ReadMapEnd()
  26231. return v, changed
  26232. }
  26233. func (d *Decoder) fastpathDecMapIntFloat32R(f *codecFnInfo, rv reflect.Value) {
  26234. if rv.Kind() == reflect.Ptr {
  26235. vp := rv2i(rv).(*map[int]float32)
  26236. if v, changed := fastpathTV.DecMapIntFloat32V(*vp, true, d); changed {
  26237. *vp = v
  26238. }
  26239. return
  26240. }
  26241. fastpathTV.DecMapIntFloat32V(rv2i(rv).(map[int]float32), false, d)
  26242. }
  26243. func (f fastpathT) DecMapIntFloat32X(vp *map[int]float32, d *Decoder) {
  26244. if v, changed := f.DecMapIntFloat32V(*vp, true, d); changed {
  26245. *vp = v
  26246. }
  26247. }
  26248. func (_ fastpathT) DecMapIntFloat32V(v map[int]float32, canChange bool,
  26249. d *Decoder) (_ map[int]float32, changed bool) {
  26250. dd, esep := d.d, d.hh.hasElemSeparators()
  26251. containerLen := dd.ReadMapStart()
  26252. if canChange && v == nil {
  26253. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  26254. v = make(map[int]float32, xlen)
  26255. changed = true
  26256. }
  26257. if containerLen == 0 {
  26258. dd.ReadMapEnd()
  26259. return v, changed
  26260. }
  26261. var mk int
  26262. var mv float32
  26263. hasLen := containerLen > 0
  26264. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26265. if esep {
  26266. dd.ReadMapElemKey()
  26267. }
  26268. mk = int(dd.DecodeInt(intBitsize))
  26269. if esep {
  26270. dd.ReadMapElemValue()
  26271. }
  26272. if dd.TryDecodeAsNil() {
  26273. if d.h.DeleteOnNilMapValue {
  26274. delete(v, mk)
  26275. } else {
  26276. v[mk] = 0
  26277. }
  26278. continue
  26279. }
  26280. mv = float32(dd.DecodeFloat(true))
  26281. if v != nil {
  26282. v[mk] = mv
  26283. }
  26284. }
  26285. dd.ReadMapEnd()
  26286. return v, changed
  26287. }
  26288. func (d *Decoder) fastpathDecMapIntFloat64R(f *codecFnInfo, rv reflect.Value) {
  26289. if rv.Kind() == reflect.Ptr {
  26290. vp := rv2i(rv).(*map[int]float64)
  26291. if v, changed := fastpathTV.DecMapIntFloat64V(*vp, true, d); changed {
  26292. *vp = v
  26293. }
  26294. return
  26295. }
  26296. fastpathTV.DecMapIntFloat64V(rv2i(rv).(map[int]float64), false, d)
  26297. }
  26298. func (f fastpathT) DecMapIntFloat64X(vp *map[int]float64, d *Decoder) {
  26299. if v, changed := f.DecMapIntFloat64V(*vp, true, d); changed {
  26300. *vp = v
  26301. }
  26302. }
  26303. func (_ fastpathT) DecMapIntFloat64V(v map[int]float64, canChange bool,
  26304. d *Decoder) (_ map[int]float64, changed bool) {
  26305. dd, esep := d.d, d.hh.hasElemSeparators()
  26306. containerLen := dd.ReadMapStart()
  26307. if canChange && v == nil {
  26308. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  26309. v = make(map[int]float64, xlen)
  26310. changed = true
  26311. }
  26312. if containerLen == 0 {
  26313. dd.ReadMapEnd()
  26314. return v, changed
  26315. }
  26316. var mk int
  26317. var mv float64
  26318. hasLen := containerLen > 0
  26319. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26320. if esep {
  26321. dd.ReadMapElemKey()
  26322. }
  26323. mk = int(dd.DecodeInt(intBitsize))
  26324. if esep {
  26325. dd.ReadMapElemValue()
  26326. }
  26327. if dd.TryDecodeAsNil() {
  26328. if d.h.DeleteOnNilMapValue {
  26329. delete(v, mk)
  26330. } else {
  26331. v[mk] = 0
  26332. }
  26333. continue
  26334. }
  26335. mv = dd.DecodeFloat(false)
  26336. if v != nil {
  26337. v[mk] = mv
  26338. }
  26339. }
  26340. dd.ReadMapEnd()
  26341. return v, changed
  26342. }
  26343. func (d *Decoder) fastpathDecMapIntBoolR(f *codecFnInfo, rv reflect.Value) {
  26344. if rv.Kind() == reflect.Ptr {
  26345. vp := rv2i(rv).(*map[int]bool)
  26346. if v, changed := fastpathTV.DecMapIntBoolV(*vp, true, d); changed {
  26347. *vp = v
  26348. }
  26349. return
  26350. }
  26351. fastpathTV.DecMapIntBoolV(rv2i(rv).(map[int]bool), false, d)
  26352. }
  26353. func (f fastpathT) DecMapIntBoolX(vp *map[int]bool, d *Decoder) {
  26354. if v, changed := f.DecMapIntBoolV(*vp, true, d); changed {
  26355. *vp = v
  26356. }
  26357. }
  26358. func (_ fastpathT) DecMapIntBoolV(v map[int]bool, canChange bool,
  26359. d *Decoder) (_ map[int]bool, changed bool) {
  26360. dd, esep := d.d, d.hh.hasElemSeparators()
  26361. containerLen := dd.ReadMapStart()
  26362. if canChange && v == nil {
  26363. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  26364. v = make(map[int]bool, xlen)
  26365. changed = true
  26366. }
  26367. if containerLen == 0 {
  26368. dd.ReadMapEnd()
  26369. return v, changed
  26370. }
  26371. var mk int
  26372. var mv bool
  26373. hasLen := containerLen > 0
  26374. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26375. if esep {
  26376. dd.ReadMapElemKey()
  26377. }
  26378. mk = int(dd.DecodeInt(intBitsize))
  26379. if esep {
  26380. dd.ReadMapElemValue()
  26381. }
  26382. if dd.TryDecodeAsNil() {
  26383. if d.h.DeleteOnNilMapValue {
  26384. delete(v, mk)
  26385. } else {
  26386. v[mk] = false
  26387. }
  26388. continue
  26389. }
  26390. mv = dd.DecodeBool()
  26391. if v != nil {
  26392. v[mk] = mv
  26393. }
  26394. }
  26395. dd.ReadMapEnd()
  26396. return v, changed
  26397. }
  26398. func (d *Decoder) fastpathDecMapInt8IntfR(f *codecFnInfo, rv reflect.Value) {
  26399. if rv.Kind() == reflect.Ptr {
  26400. vp := rv2i(rv).(*map[int8]interface{})
  26401. if v, changed := fastpathTV.DecMapInt8IntfV(*vp, true, d); changed {
  26402. *vp = v
  26403. }
  26404. return
  26405. }
  26406. fastpathTV.DecMapInt8IntfV(rv2i(rv).(map[int8]interface{}), false, d)
  26407. }
  26408. func (f fastpathT) DecMapInt8IntfX(vp *map[int8]interface{}, d *Decoder) {
  26409. if v, changed := f.DecMapInt8IntfV(*vp, true, d); changed {
  26410. *vp = v
  26411. }
  26412. }
  26413. func (_ fastpathT) DecMapInt8IntfV(v map[int8]interface{}, canChange bool,
  26414. d *Decoder) (_ map[int8]interface{}, changed bool) {
  26415. dd, esep := d.d, d.hh.hasElemSeparators()
  26416. containerLen := dd.ReadMapStart()
  26417. if canChange && v == nil {
  26418. xlen := decInferLen(containerLen, d.h.MaxInitLen, 17)
  26419. v = make(map[int8]interface{}, xlen)
  26420. changed = true
  26421. }
  26422. if containerLen == 0 {
  26423. dd.ReadMapEnd()
  26424. return v, changed
  26425. }
  26426. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  26427. var mk int8
  26428. var mv interface{}
  26429. hasLen := containerLen > 0
  26430. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26431. if esep {
  26432. dd.ReadMapElemKey()
  26433. }
  26434. mk = int8(dd.DecodeInt(8))
  26435. if esep {
  26436. dd.ReadMapElemValue()
  26437. }
  26438. if dd.TryDecodeAsNil() {
  26439. if d.h.DeleteOnNilMapValue {
  26440. delete(v, mk)
  26441. } else {
  26442. v[mk] = nil
  26443. }
  26444. continue
  26445. }
  26446. if mapGet {
  26447. mv = v[mk]
  26448. } else {
  26449. mv = nil
  26450. }
  26451. d.decode(&mv)
  26452. if v != nil {
  26453. v[mk] = mv
  26454. }
  26455. }
  26456. dd.ReadMapEnd()
  26457. return v, changed
  26458. }
  26459. func (d *Decoder) fastpathDecMapInt8StringR(f *codecFnInfo, rv reflect.Value) {
  26460. if rv.Kind() == reflect.Ptr {
  26461. vp := rv2i(rv).(*map[int8]string)
  26462. if v, changed := fastpathTV.DecMapInt8StringV(*vp, true, d); changed {
  26463. *vp = v
  26464. }
  26465. return
  26466. }
  26467. fastpathTV.DecMapInt8StringV(rv2i(rv).(map[int8]string), false, d)
  26468. }
  26469. func (f fastpathT) DecMapInt8StringX(vp *map[int8]string, d *Decoder) {
  26470. if v, changed := f.DecMapInt8StringV(*vp, true, d); changed {
  26471. *vp = v
  26472. }
  26473. }
  26474. func (_ fastpathT) DecMapInt8StringV(v map[int8]string, canChange bool,
  26475. d *Decoder) (_ map[int8]string, changed bool) {
  26476. dd, esep := d.d, d.hh.hasElemSeparators()
  26477. containerLen := dd.ReadMapStart()
  26478. if canChange && v == nil {
  26479. xlen := decInferLen(containerLen, d.h.MaxInitLen, 17)
  26480. v = make(map[int8]string, xlen)
  26481. changed = true
  26482. }
  26483. if containerLen == 0 {
  26484. dd.ReadMapEnd()
  26485. return v, changed
  26486. }
  26487. var mk int8
  26488. var mv string
  26489. hasLen := containerLen > 0
  26490. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26491. if esep {
  26492. dd.ReadMapElemKey()
  26493. }
  26494. mk = int8(dd.DecodeInt(8))
  26495. if esep {
  26496. dd.ReadMapElemValue()
  26497. }
  26498. if dd.TryDecodeAsNil() {
  26499. if d.h.DeleteOnNilMapValue {
  26500. delete(v, mk)
  26501. } else {
  26502. v[mk] = ""
  26503. }
  26504. continue
  26505. }
  26506. mv = dd.DecodeString()
  26507. if v != nil {
  26508. v[mk] = mv
  26509. }
  26510. }
  26511. dd.ReadMapEnd()
  26512. return v, changed
  26513. }
  26514. func (d *Decoder) fastpathDecMapInt8UintR(f *codecFnInfo, rv reflect.Value) {
  26515. if rv.Kind() == reflect.Ptr {
  26516. vp := rv2i(rv).(*map[int8]uint)
  26517. if v, changed := fastpathTV.DecMapInt8UintV(*vp, true, d); changed {
  26518. *vp = v
  26519. }
  26520. return
  26521. }
  26522. fastpathTV.DecMapInt8UintV(rv2i(rv).(map[int8]uint), false, d)
  26523. }
  26524. func (f fastpathT) DecMapInt8UintX(vp *map[int8]uint, d *Decoder) {
  26525. if v, changed := f.DecMapInt8UintV(*vp, true, d); changed {
  26526. *vp = v
  26527. }
  26528. }
  26529. func (_ fastpathT) DecMapInt8UintV(v map[int8]uint, canChange bool,
  26530. d *Decoder) (_ map[int8]uint, changed bool) {
  26531. dd, esep := d.d, d.hh.hasElemSeparators()
  26532. containerLen := dd.ReadMapStart()
  26533. if canChange && v == nil {
  26534. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  26535. v = make(map[int8]uint, xlen)
  26536. changed = true
  26537. }
  26538. if containerLen == 0 {
  26539. dd.ReadMapEnd()
  26540. return v, changed
  26541. }
  26542. var mk int8
  26543. var mv uint
  26544. hasLen := containerLen > 0
  26545. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26546. if esep {
  26547. dd.ReadMapElemKey()
  26548. }
  26549. mk = int8(dd.DecodeInt(8))
  26550. if esep {
  26551. dd.ReadMapElemValue()
  26552. }
  26553. if dd.TryDecodeAsNil() {
  26554. if d.h.DeleteOnNilMapValue {
  26555. delete(v, mk)
  26556. } else {
  26557. v[mk] = 0
  26558. }
  26559. continue
  26560. }
  26561. mv = uint(dd.DecodeUint(uintBitsize))
  26562. if v != nil {
  26563. v[mk] = mv
  26564. }
  26565. }
  26566. dd.ReadMapEnd()
  26567. return v, changed
  26568. }
  26569. func (d *Decoder) fastpathDecMapInt8Uint8R(f *codecFnInfo, rv reflect.Value) {
  26570. if rv.Kind() == reflect.Ptr {
  26571. vp := rv2i(rv).(*map[int8]uint8)
  26572. if v, changed := fastpathTV.DecMapInt8Uint8V(*vp, true, d); changed {
  26573. *vp = v
  26574. }
  26575. return
  26576. }
  26577. fastpathTV.DecMapInt8Uint8V(rv2i(rv).(map[int8]uint8), false, d)
  26578. }
  26579. func (f fastpathT) DecMapInt8Uint8X(vp *map[int8]uint8, d *Decoder) {
  26580. if v, changed := f.DecMapInt8Uint8V(*vp, true, d); changed {
  26581. *vp = v
  26582. }
  26583. }
  26584. func (_ fastpathT) DecMapInt8Uint8V(v map[int8]uint8, canChange bool,
  26585. d *Decoder) (_ map[int8]uint8, changed bool) {
  26586. dd, esep := d.d, d.hh.hasElemSeparators()
  26587. containerLen := dd.ReadMapStart()
  26588. if canChange && v == nil {
  26589. xlen := decInferLen(containerLen, d.h.MaxInitLen, 2)
  26590. v = make(map[int8]uint8, xlen)
  26591. changed = true
  26592. }
  26593. if containerLen == 0 {
  26594. dd.ReadMapEnd()
  26595. return v, changed
  26596. }
  26597. var mk int8
  26598. var mv uint8
  26599. hasLen := containerLen > 0
  26600. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26601. if esep {
  26602. dd.ReadMapElemKey()
  26603. }
  26604. mk = int8(dd.DecodeInt(8))
  26605. if esep {
  26606. dd.ReadMapElemValue()
  26607. }
  26608. if dd.TryDecodeAsNil() {
  26609. if d.h.DeleteOnNilMapValue {
  26610. delete(v, mk)
  26611. } else {
  26612. v[mk] = 0
  26613. }
  26614. continue
  26615. }
  26616. mv = uint8(dd.DecodeUint(8))
  26617. if v != nil {
  26618. v[mk] = mv
  26619. }
  26620. }
  26621. dd.ReadMapEnd()
  26622. return v, changed
  26623. }
  26624. func (d *Decoder) fastpathDecMapInt8Uint16R(f *codecFnInfo, rv reflect.Value) {
  26625. if rv.Kind() == reflect.Ptr {
  26626. vp := rv2i(rv).(*map[int8]uint16)
  26627. if v, changed := fastpathTV.DecMapInt8Uint16V(*vp, true, d); changed {
  26628. *vp = v
  26629. }
  26630. return
  26631. }
  26632. fastpathTV.DecMapInt8Uint16V(rv2i(rv).(map[int8]uint16), false, d)
  26633. }
  26634. func (f fastpathT) DecMapInt8Uint16X(vp *map[int8]uint16, d *Decoder) {
  26635. if v, changed := f.DecMapInt8Uint16V(*vp, true, d); changed {
  26636. *vp = v
  26637. }
  26638. }
  26639. func (_ fastpathT) DecMapInt8Uint16V(v map[int8]uint16, canChange bool,
  26640. d *Decoder) (_ map[int8]uint16, changed bool) {
  26641. dd, esep := d.d, d.hh.hasElemSeparators()
  26642. containerLen := dd.ReadMapStart()
  26643. if canChange && v == nil {
  26644. xlen := decInferLen(containerLen, d.h.MaxInitLen, 3)
  26645. v = make(map[int8]uint16, xlen)
  26646. changed = true
  26647. }
  26648. if containerLen == 0 {
  26649. dd.ReadMapEnd()
  26650. return v, changed
  26651. }
  26652. var mk int8
  26653. var mv uint16
  26654. hasLen := containerLen > 0
  26655. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26656. if esep {
  26657. dd.ReadMapElemKey()
  26658. }
  26659. mk = int8(dd.DecodeInt(8))
  26660. if esep {
  26661. dd.ReadMapElemValue()
  26662. }
  26663. if dd.TryDecodeAsNil() {
  26664. if d.h.DeleteOnNilMapValue {
  26665. delete(v, mk)
  26666. } else {
  26667. v[mk] = 0
  26668. }
  26669. continue
  26670. }
  26671. mv = uint16(dd.DecodeUint(16))
  26672. if v != nil {
  26673. v[mk] = mv
  26674. }
  26675. }
  26676. dd.ReadMapEnd()
  26677. return v, changed
  26678. }
  26679. func (d *Decoder) fastpathDecMapInt8Uint32R(f *codecFnInfo, rv reflect.Value) {
  26680. if rv.Kind() == reflect.Ptr {
  26681. vp := rv2i(rv).(*map[int8]uint32)
  26682. if v, changed := fastpathTV.DecMapInt8Uint32V(*vp, true, d); changed {
  26683. *vp = v
  26684. }
  26685. return
  26686. }
  26687. fastpathTV.DecMapInt8Uint32V(rv2i(rv).(map[int8]uint32), false, d)
  26688. }
  26689. func (f fastpathT) DecMapInt8Uint32X(vp *map[int8]uint32, d *Decoder) {
  26690. if v, changed := f.DecMapInt8Uint32V(*vp, true, d); changed {
  26691. *vp = v
  26692. }
  26693. }
  26694. func (_ fastpathT) DecMapInt8Uint32V(v map[int8]uint32, canChange bool,
  26695. d *Decoder) (_ map[int8]uint32, changed bool) {
  26696. dd, esep := d.d, d.hh.hasElemSeparators()
  26697. containerLen := dd.ReadMapStart()
  26698. if canChange && v == nil {
  26699. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  26700. v = make(map[int8]uint32, xlen)
  26701. changed = true
  26702. }
  26703. if containerLen == 0 {
  26704. dd.ReadMapEnd()
  26705. return v, changed
  26706. }
  26707. var mk int8
  26708. var mv uint32
  26709. hasLen := containerLen > 0
  26710. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26711. if esep {
  26712. dd.ReadMapElemKey()
  26713. }
  26714. mk = int8(dd.DecodeInt(8))
  26715. if esep {
  26716. dd.ReadMapElemValue()
  26717. }
  26718. if dd.TryDecodeAsNil() {
  26719. if d.h.DeleteOnNilMapValue {
  26720. delete(v, mk)
  26721. } else {
  26722. v[mk] = 0
  26723. }
  26724. continue
  26725. }
  26726. mv = uint32(dd.DecodeUint(32))
  26727. if v != nil {
  26728. v[mk] = mv
  26729. }
  26730. }
  26731. dd.ReadMapEnd()
  26732. return v, changed
  26733. }
  26734. func (d *Decoder) fastpathDecMapInt8Uint64R(f *codecFnInfo, rv reflect.Value) {
  26735. if rv.Kind() == reflect.Ptr {
  26736. vp := rv2i(rv).(*map[int8]uint64)
  26737. if v, changed := fastpathTV.DecMapInt8Uint64V(*vp, true, d); changed {
  26738. *vp = v
  26739. }
  26740. return
  26741. }
  26742. fastpathTV.DecMapInt8Uint64V(rv2i(rv).(map[int8]uint64), false, d)
  26743. }
  26744. func (f fastpathT) DecMapInt8Uint64X(vp *map[int8]uint64, d *Decoder) {
  26745. if v, changed := f.DecMapInt8Uint64V(*vp, true, d); changed {
  26746. *vp = v
  26747. }
  26748. }
  26749. func (_ fastpathT) DecMapInt8Uint64V(v map[int8]uint64, canChange bool,
  26750. d *Decoder) (_ map[int8]uint64, changed bool) {
  26751. dd, esep := d.d, d.hh.hasElemSeparators()
  26752. containerLen := dd.ReadMapStart()
  26753. if canChange && v == nil {
  26754. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  26755. v = make(map[int8]uint64, xlen)
  26756. changed = true
  26757. }
  26758. if containerLen == 0 {
  26759. dd.ReadMapEnd()
  26760. return v, changed
  26761. }
  26762. var mk int8
  26763. var mv uint64
  26764. hasLen := containerLen > 0
  26765. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26766. if esep {
  26767. dd.ReadMapElemKey()
  26768. }
  26769. mk = int8(dd.DecodeInt(8))
  26770. if esep {
  26771. dd.ReadMapElemValue()
  26772. }
  26773. if dd.TryDecodeAsNil() {
  26774. if d.h.DeleteOnNilMapValue {
  26775. delete(v, mk)
  26776. } else {
  26777. v[mk] = 0
  26778. }
  26779. continue
  26780. }
  26781. mv = dd.DecodeUint(64)
  26782. if v != nil {
  26783. v[mk] = mv
  26784. }
  26785. }
  26786. dd.ReadMapEnd()
  26787. return v, changed
  26788. }
  26789. func (d *Decoder) fastpathDecMapInt8UintptrR(f *codecFnInfo, rv reflect.Value) {
  26790. if rv.Kind() == reflect.Ptr {
  26791. vp := rv2i(rv).(*map[int8]uintptr)
  26792. if v, changed := fastpathTV.DecMapInt8UintptrV(*vp, true, d); changed {
  26793. *vp = v
  26794. }
  26795. return
  26796. }
  26797. fastpathTV.DecMapInt8UintptrV(rv2i(rv).(map[int8]uintptr), false, d)
  26798. }
  26799. func (f fastpathT) DecMapInt8UintptrX(vp *map[int8]uintptr, d *Decoder) {
  26800. if v, changed := f.DecMapInt8UintptrV(*vp, true, d); changed {
  26801. *vp = v
  26802. }
  26803. }
  26804. func (_ fastpathT) DecMapInt8UintptrV(v map[int8]uintptr, canChange bool,
  26805. d *Decoder) (_ map[int8]uintptr, changed bool) {
  26806. dd, esep := d.d, d.hh.hasElemSeparators()
  26807. containerLen := dd.ReadMapStart()
  26808. if canChange && v == nil {
  26809. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  26810. v = make(map[int8]uintptr, xlen)
  26811. changed = true
  26812. }
  26813. if containerLen == 0 {
  26814. dd.ReadMapEnd()
  26815. return v, changed
  26816. }
  26817. var mk int8
  26818. var mv uintptr
  26819. hasLen := containerLen > 0
  26820. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26821. if esep {
  26822. dd.ReadMapElemKey()
  26823. }
  26824. mk = int8(dd.DecodeInt(8))
  26825. if esep {
  26826. dd.ReadMapElemValue()
  26827. }
  26828. if dd.TryDecodeAsNil() {
  26829. if d.h.DeleteOnNilMapValue {
  26830. delete(v, mk)
  26831. } else {
  26832. v[mk] = 0
  26833. }
  26834. continue
  26835. }
  26836. mv = uintptr(dd.DecodeUint(uintBitsize))
  26837. if v != nil {
  26838. v[mk] = mv
  26839. }
  26840. }
  26841. dd.ReadMapEnd()
  26842. return v, changed
  26843. }
  26844. func (d *Decoder) fastpathDecMapInt8IntR(f *codecFnInfo, rv reflect.Value) {
  26845. if rv.Kind() == reflect.Ptr {
  26846. vp := rv2i(rv).(*map[int8]int)
  26847. if v, changed := fastpathTV.DecMapInt8IntV(*vp, true, d); changed {
  26848. *vp = v
  26849. }
  26850. return
  26851. }
  26852. fastpathTV.DecMapInt8IntV(rv2i(rv).(map[int8]int), false, d)
  26853. }
  26854. func (f fastpathT) DecMapInt8IntX(vp *map[int8]int, d *Decoder) {
  26855. if v, changed := f.DecMapInt8IntV(*vp, true, d); changed {
  26856. *vp = v
  26857. }
  26858. }
  26859. func (_ fastpathT) DecMapInt8IntV(v map[int8]int, canChange bool,
  26860. d *Decoder) (_ map[int8]int, changed bool) {
  26861. dd, esep := d.d, d.hh.hasElemSeparators()
  26862. containerLen := dd.ReadMapStart()
  26863. if canChange && v == nil {
  26864. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  26865. v = make(map[int8]int, xlen)
  26866. changed = true
  26867. }
  26868. if containerLen == 0 {
  26869. dd.ReadMapEnd()
  26870. return v, changed
  26871. }
  26872. var mk int8
  26873. var mv int
  26874. hasLen := containerLen > 0
  26875. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26876. if esep {
  26877. dd.ReadMapElemKey()
  26878. }
  26879. mk = int8(dd.DecodeInt(8))
  26880. if esep {
  26881. dd.ReadMapElemValue()
  26882. }
  26883. if dd.TryDecodeAsNil() {
  26884. if d.h.DeleteOnNilMapValue {
  26885. delete(v, mk)
  26886. } else {
  26887. v[mk] = 0
  26888. }
  26889. continue
  26890. }
  26891. mv = int(dd.DecodeInt(intBitsize))
  26892. if v != nil {
  26893. v[mk] = mv
  26894. }
  26895. }
  26896. dd.ReadMapEnd()
  26897. return v, changed
  26898. }
  26899. func (d *Decoder) fastpathDecMapInt8Int8R(f *codecFnInfo, rv reflect.Value) {
  26900. if rv.Kind() == reflect.Ptr {
  26901. vp := rv2i(rv).(*map[int8]int8)
  26902. if v, changed := fastpathTV.DecMapInt8Int8V(*vp, true, d); changed {
  26903. *vp = v
  26904. }
  26905. return
  26906. }
  26907. fastpathTV.DecMapInt8Int8V(rv2i(rv).(map[int8]int8), false, d)
  26908. }
  26909. func (f fastpathT) DecMapInt8Int8X(vp *map[int8]int8, d *Decoder) {
  26910. if v, changed := f.DecMapInt8Int8V(*vp, true, d); changed {
  26911. *vp = v
  26912. }
  26913. }
  26914. func (_ fastpathT) DecMapInt8Int8V(v map[int8]int8, canChange bool,
  26915. d *Decoder) (_ map[int8]int8, changed bool) {
  26916. dd, esep := d.d, d.hh.hasElemSeparators()
  26917. containerLen := dd.ReadMapStart()
  26918. if canChange && v == nil {
  26919. xlen := decInferLen(containerLen, d.h.MaxInitLen, 2)
  26920. v = make(map[int8]int8, xlen)
  26921. changed = true
  26922. }
  26923. if containerLen == 0 {
  26924. dd.ReadMapEnd()
  26925. return v, changed
  26926. }
  26927. var mk int8
  26928. var mv int8
  26929. hasLen := containerLen > 0
  26930. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26931. if esep {
  26932. dd.ReadMapElemKey()
  26933. }
  26934. mk = int8(dd.DecodeInt(8))
  26935. if esep {
  26936. dd.ReadMapElemValue()
  26937. }
  26938. if dd.TryDecodeAsNil() {
  26939. if d.h.DeleteOnNilMapValue {
  26940. delete(v, mk)
  26941. } else {
  26942. v[mk] = 0
  26943. }
  26944. continue
  26945. }
  26946. mv = int8(dd.DecodeInt(8))
  26947. if v != nil {
  26948. v[mk] = mv
  26949. }
  26950. }
  26951. dd.ReadMapEnd()
  26952. return v, changed
  26953. }
  26954. func (d *Decoder) fastpathDecMapInt8Int16R(f *codecFnInfo, rv reflect.Value) {
  26955. if rv.Kind() == reflect.Ptr {
  26956. vp := rv2i(rv).(*map[int8]int16)
  26957. if v, changed := fastpathTV.DecMapInt8Int16V(*vp, true, d); changed {
  26958. *vp = v
  26959. }
  26960. return
  26961. }
  26962. fastpathTV.DecMapInt8Int16V(rv2i(rv).(map[int8]int16), false, d)
  26963. }
  26964. func (f fastpathT) DecMapInt8Int16X(vp *map[int8]int16, d *Decoder) {
  26965. if v, changed := f.DecMapInt8Int16V(*vp, true, d); changed {
  26966. *vp = v
  26967. }
  26968. }
  26969. func (_ fastpathT) DecMapInt8Int16V(v map[int8]int16, canChange bool,
  26970. d *Decoder) (_ map[int8]int16, changed bool) {
  26971. dd, esep := d.d, d.hh.hasElemSeparators()
  26972. containerLen := dd.ReadMapStart()
  26973. if canChange && v == nil {
  26974. xlen := decInferLen(containerLen, d.h.MaxInitLen, 3)
  26975. v = make(map[int8]int16, xlen)
  26976. changed = true
  26977. }
  26978. if containerLen == 0 {
  26979. dd.ReadMapEnd()
  26980. return v, changed
  26981. }
  26982. var mk int8
  26983. var mv int16
  26984. hasLen := containerLen > 0
  26985. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26986. if esep {
  26987. dd.ReadMapElemKey()
  26988. }
  26989. mk = int8(dd.DecodeInt(8))
  26990. if esep {
  26991. dd.ReadMapElemValue()
  26992. }
  26993. if dd.TryDecodeAsNil() {
  26994. if d.h.DeleteOnNilMapValue {
  26995. delete(v, mk)
  26996. } else {
  26997. v[mk] = 0
  26998. }
  26999. continue
  27000. }
  27001. mv = int16(dd.DecodeInt(16))
  27002. if v != nil {
  27003. v[mk] = mv
  27004. }
  27005. }
  27006. dd.ReadMapEnd()
  27007. return v, changed
  27008. }
  27009. func (d *Decoder) fastpathDecMapInt8Int32R(f *codecFnInfo, rv reflect.Value) {
  27010. if rv.Kind() == reflect.Ptr {
  27011. vp := rv2i(rv).(*map[int8]int32)
  27012. if v, changed := fastpathTV.DecMapInt8Int32V(*vp, true, d); changed {
  27013. *vp = v
  27014. }
  27015. return
  27016. }
  27017. fastpathTV.DecMapInt8Int32V(rv2i(rv).(map[int8]int32), false, d)
  27018. }
  27019. func (f fastpathT) DecMapInt8Int32X(vp *map[int8]int32, d *Decoder) {
  27020. if v, changed := f.DecMapInt8Int32V(*vp, true, d); changed {
  27021. *vp = v
  27022. }
  27023. }
  27024. func (_ fastpathT) DecMapInt8Int32V(v map[int8]int32, canChange bool,
  27025. d *Decoder) (_ map[int8]int32, changed bool) {
  27026. dd, esep := d.d, d.hh.hasElemSeparators()
  27027. containerLen := dd.ReadMapStart()
  27028. if canChange && v == nil {
  27029. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  27030. v = make(map[int8]int32, xlen)
  27031. changed = true
  27032. }
  27033. if containerLen == 0 {
  27034. dd.ReadMapEnd()
  27035. return v, changed
  27036. }
  27037. var mk int8
  27038. var mv int32
  27039. hasLen := containerLen > 0
  27040. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27041. if esep {
  27042. dd.ReadMapElemKey()
  27043. }
  27044. mk = int8(dd.DecodeInt(8))
  27045. if esep {
  27046. dd.ReadMapElemValue()
  27047. }
  27048. if dd.TryDecodeAsNil() {
  27049. if d.h.DeleteOnNilMapValue {
  27050. delete(v, mk)
  27051. } else {
  27052. v[mk] = 0
  27053. }
  27054. continue
  27055. }
  27056. mv = int32(dd.DecodeInt(32))
  27057. if v != nil {
  27058. v[mk] = mv
  27059. }
  27060. }
  27061. dd.ReadMapEnd()
  27062. return v, changed
  27063. }
  27064. func (d *Decoder) fastpathDecMapInt8Int64R(f *codecFnInfo, rv reflect.Value) {
  27065. if rv.Kind() == reflect.Ptr {
  27066. vp := rv2i(rv).(*map[int8]int64)
  27067. if v, changed := fastpathTV.DecMapInt8Int64V(*vp, true, d); changed {
  27068. *vp = v
  27069. }
  27070. return
  27071. }
  27072. fastpathTV.DecMapInt8Int64V(rv2i(rv).(map[int8]int64), false, d)
  27073. }
  27074. func (f fastpathT) DecMapInt8Int64X(vp *map[int8]int64, d *Decoder) {
  27075. if v, changed := f.DecMapInt8Int64V(*vp, true, d); changed {
  27076. *vp = v
  27077. }
  27078. }
  27079. func (_ fastpathT) DecMapInt8Int64V(v map[int8]int64, canChange bool,
  27080. d *Decoder) (_ map[int8]int64, changed bool) {
  27081. dd, esep := d.d, d.hh.hasElemSeparators()
  27082. containerLen := dd.ReadMapStart()
  27083. if canChange && v == nil {
  27084. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  27085. v = make(map[int8]int64, xlen)
  27086. changed = true
  27087. }
  27088. if containerLen == 0 {
  27089. dd.ReadMapEnd()
  27090. return v, changed
  27091. }
  27092. var mk int8
  27093. var mv int64
  27094. hasLen := containerLen > 0
  27095. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27096. if esep {
  27097. dd.ReadMapElemKey()
  27098. }
  27099. mk = int8(dd.DecodeInt(8))
  27100. if esep {
  27101. dd.ReadMapElemValue()
  27102. }
  27103. if dd.TryDecodeAsNil() {
  27104. if d.h.DeleteOnNilMapValue {
  27105. delete(v, mk)
  27106. } else {
  27107. v[mk] = 0
  27108. }
  27109. continue
  27110. }
  27111. mv = dd.DecodeInt(64)
  27112. if v != nil {
  27113. v[mk] = mv
  27114. }
  27115. }
  27116. dd.ReadMapEnd()
  27117. return v, changed
  27118. }
  27119. func (d *Decoder) fastpathDecMapInt8Float32R(f *codecFnInfo, rv reflect.Value) {
  27120. if rv.Kind() == reflect.Ptr {
  27121. vp := rv2i(rv).(*map[int8]float32)
  27122. if v, changed := fastpathTV.DecMapInt8Float32V(*vp, true, d); changed {
  27123. *vp = v
  27124. }
  27125. return
  27126. }
  27127. fastpathTV.DecMapInt8Float32V(rv2i(rv).(map[int8]float32), false, d)
  27128. }
  27129. func (f fastpathT) DecMapInt8Float32X(vp *map[int8]float32, d *Decoder) {
  27130. if v, changed := f.DecMapInt8Float32V(*vp, true, d); changed {
  27131. *vp = v
  27132. }
  27133. }
  27134. func (_ fastpathT) DecMapInt8Float32V(v map[int8]float32, canChange bool,
  27135. d *Decoder) (_ map[int8]float32, changed bool) {
  27136. dd, esep := d.d, d.hh.hasElemSeparators()
  27137. containerLen := dd.ReadMapStart()
  27138. if canChange && v == nil {
  27139. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  27140. v = make(map[int8]float32, xlen)
  27141. changed = true
  27142. }
  27143. if containerLen == 0 {
  27144. dd.ReadMapEnd()
  27145. return v, changed
  27146. }
  27147. var mk int8
  27148. var mv float32
  27149. hasLen := containerLen > 0
  27150. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27151. if esep {
  27152. dd.ReadMapElemKey()
  27153. }
  27154. mk = int8(dd.DecodeInt(8))
  27155. if esep {
  27156. dd.ReadMapElemValue()
  27157. }
  27158. if dd.TryDecodeAsNil() {
  27159. if d.h.DeleteOnNilMapValue {
  27160. delete(v, mk)
  27161. } else {
  27162. v[mk] = 0
  27163. }
  27164. continue
  27165. }
  27166. mv = float32(dd.DecodeFloat(true))
  27167. if v != nil {
  27168. v[mk] = mv
  27169. }
  27170. }
  27171. dd.ReadMapEnd()
  27172. return v, changed
  27173. }
  27174. func (d *Decoder) fastpathDecMapInt8Float64R(f *codecFnInfo, rv reflect.Value) {
  27175. if rv.Kind() == reflect.Ptr {
  27176. vp := rv2i(rv).(*map[int8]float64)
  27177. if v, changed := fastpathTV.DecMapInt8Float64V(*vp, true, d); changed {
  27178. *vp = v
  27179. }
  27180. return
  27181. }
  27182. fastpathTV.DecMapInt8Float64V(rv2i(rv).(map[int8]float64), false, d)
  27183. }
  27184. func (f fastpathT) DecMapInt8Float64X(vp *map[int8]float64, d *Decoder) {
  27185. if v, changed := f.DecMapInt8Float64V(*vp, true, d); changed {
  27186. *vp = v
  27187. }
  27188. }
  27189. func (_ fastpathT) DecMapInt8Float64V(v map[int8]float64, canChange bool,
  27190. d *Decoder) (_ map[int8]float64, changed bool) {
  27191. dd, esep := d.d, d.hh.hasElemSeparators()
  27192. containerLen := dd.ReadMapStart()
  27193. if canChange && v == nil {
  27194. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  27195. v = make(map[int8]float64, xlen)
  27196. changed = true
  27197. }
  27198. if containerLen == 0 {
  27199. dd.ReadMapEnd()
  27200. return v, changed
  27201. }
  27202. var mk int8
  27203. var mv float64
  27204. hasLen := containerLen > 0
  27205. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27206. if esep {
  27207. dd.ReadMapElemKey()
  27208. }
  27209. mk = int8(dd.DecodeInt(8))
  27210. if esep {
  27211. dd.ReadMapElemValue()
  27212. }
  27213. if dd.TryDecodeAsNil() {
  27214. if d.h.DeleteOnNilMapValue {
  27215. delete(v, mk)
  27216. } else {
  27217. v[mk] = 0
  27218. }
  27219. continue
  27220. }
  27221. mv = dd.DecodeFloat(false)
  27222. if v != nil {
  27223. v[mk] = mv
  27224. }
  27225. }
  27226. dd.ReadMapEnd()
  27227. return v, changed
  27228. }
  27229. func (d *Decoder) fastpathDecMapInt8BoolR(f *codecFnInfo, rv reflect.Value) {
  27230. if rv.Kind() == reflect.Ptr {
  27231. vp := rv2i(rv).(*map[int8]bool)
  27232. if v, changed := fastpathTV.DecMapInt8BoolV(*vp, true, d); changed {
  27233. *vp = v
  27234. }
  27235. return
  27236. }
  27237. fastpathTV.DecMapInt8BoolV(rv2i(rv).(map[int8]bool), false, d)
  27238. }
  27239. func (f fastpathT) DecMapInt8BoolX(vp *map[int8]bool, d *Decoder) {
  27240. if v, changed := f.DecMapInt8BoolV(*vp, true, d); changed {
  27241. *vp = v
  27242. }
  27243. }
  27244. func (_ fastpathT) DecMapInt8BoolV(v map[int8]bool, canChange bool,
  27245. d *Decoder) (_ map[int8]bool, changed bool) {
  27246. dd, esep := d.d, d.hh.hasElemSeparators()
  27247. containerLen := dd.ReadMapStart()
  27248. if canChange && v == nil {
  27249. xlen := decInferLen(containerLen, d.h.MaxInitLen, 2)
  27250. v = make(map[int8]bool, xlen)
  27251. changed = true
  27252. }
  27253. if containerLen == 0 {
  27254. dd.ReadMapEnd()
  27255. return v, changed
  27256. }
  27257. var mk int8
  27258. var mv bool
  27259. hasLen := containerLen > 0
  27260. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27261. if esep {
  27262. dd.ReadMapElemKey()
  27263. }
  27264. mk = int8(dd.DecodeInt(8))
  27265. if esep {
  27266. dd.ReadMapElemValue()
  27267. }
  27268. if dd.TryDecodeAsNil() {
  27269. if d.h.DeleteOnNilMapValue {
  27270. delete(v, mk)
  27271. } else {
  27272. v[mk] = false
  27273. }
  27274. continue
  27275. }
  27276. mv = dd.DecodeBool()
  27277. if v != nil {
  27278. v[mk] = mv
  27279. }
  27280. }
  27281. dd.ReadMapEnd()
  27282. return v, changed
  27283. }
  27284. func (d *Decoder) fastpathDecMapInt16IntfR(f *codecFnInfo, rv reflect.Value) {
  27285. if rv.Kind() == reflect.Ptr {
  27286. vp := rv2i(rv).(*map[int16]interface{})
  27287. if v, changed := fastpathTV.DecMapInt16IntfV(*vp, true, d); changed {
  27288. *vp = v
  27289. }
  27290. return
  27291. }
  27292. fastpathTV.DecMapInt16IntfV(rv2i(rv).(map[int16]interface{}), false, d)
  27293. }
  27294. func (f fastpathT) DecMapInt16IntfX(vp *map[int16]interface{}, d *Decoder) {
  27295. if v, changed := f.DecMapInt16IntfV(*vp, true, d); changed {
  27296. *vp = v
  27297. }
  27298. }
  27299. func (_ fastpathT) DecMapInt16IntfV(v map[int16]interface{}, canChange bool,
  27300. d *Decoder) (_ map[int16]interface{}, changed bool) {
  27301. dd, esep := d.d, d.hh.hasElemSeparators()
  27302. containerLen := dd.ReadMapStart()
  27303. if canChange && v == nil {
  27304. xlen := decInferLen(containerLen, d.h.MaxInitLen, 18)
  27305. v = make(map[int16]interface{}, xlen)
  27306. changed = true
  27307. }
  27308. if containerLen == 0 {
  27309. dd.ReadMapEnd()
  27310. return v, changed
  27311. }
  27312. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  27313. var mk int16
  27314. var mv interface{}
  27315. hasLen := containerLen > 0
  27316. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27317. if esep {
  27318. dd.ReadMapElemKey()
  27319. }
  27320. mk = int16(dd.DecodeInt(16))
  27321. if esep {
  27322. dd.ReadMapElemValue()
  27323. }
  27324. if dd.TryDecodeAsNil() {
  27325. if d.h.DeleteOnNilMapValue {
  27326. delete(v, mk)
  27327. } else {
  27328. v[mk] = nil
  27329. }
  27330. continue
  27331. }
  27332. if mapGet {
  27333. mv = v[mk]
  27334. } else {
  27335. mv = nil
  27336. }
  27337. d.decode(&mv)
  27338. if v != nil {
  27339. v[mk] = mv
  27340. }
  27341. }
  27342. dd.ReadMapEnd()
  27343. return v, changed
  27344. }
  27345. func (d *Decoder) fastpathDecMapInt16StringR(f *codecFnInfo, rv reflect.Value) {
  27346. if rv.Kind() == reflect.Ptr {
  27347. vp := rv2i(rv).(*map[int16]string)
  27348. if v, changed := fastpathTV.DecMapInt16StringV(*vp, true, d); changed {
  27349. *vp = v
  27350. }
  27351. return
  27352. }
  27353. fastpathTV.DecMapInt16StringV(rv2i(rv).(map[int16]string), false, d)
  27354. }
  27355. func (f fastpathT) DecMapInt16StringX(vp *map[int16]string, d *Decoder) {
  27356. if v, changed := f.DecMapInt16StringV(*vp, true, d); changed {
  27357. *vp = v
  27358. }
  27359. }
  27360. func (_ fastpathT) DecMapInt16StringV(v map[int16]string, canChange bool,
  27361. d *Decoder) (_ map[int16]string, changed bool) {
  27362. dd, esep := d.d, d.hh.hasElemSeparators()
  27363. containerLen := dd.ReadMapStart()
  27364. if canChange && v == nil {
  27365. xlen := decInferLen(containerLen, d.h.MaxInitLen, 18)
  27366. v = make(map[int16]string, xlen)
  27367. changed = true
  27368. }
  27369. if containerLen == 0 {
  27370. dd.ReadMapEnd()
  27371. return v, changed
  27372. }
  27373. var mk int16
  27374. var mv string
  27375. hasLen := containerLen > 0
  27376. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27377. if esep {
  27378. dd.ReadMapElemKey()
  27379. }
  27380. mk = int16(dd.DecodeInt(16))
  27381. if esep {
  27382. dd.ReadMapElemValue()
  27383. }
  27384. if dd.TryDecodeAsNil() {
  27385. if d.h.DeleteOnNilMapValue {
  27386. delete(v, mk)
  27387. } else {
  27388. v[mk] = ""
  27389. }
  27390. continue
  27391. }
  27392. mv = dd.DecodeString()
  27393. if v != nil {
  27394. v[mk] = mv
  27395. }
  27396. }
  27397. dd.ReadMapEnd()
  27398. return v, changed
  27399. }
  27400. func (d *Decoder) fastpathDecMapInt16UintR(f *codecFnInfo, rv reflect.Value) {
  27401. if rv.Kind() == reflect.Ptr {
  27402. vp := rv2i(rv).(*map[int16]uint)
  27403. if v, changed := fastpathTV.DecMapInt16UintV(*vp, true, d); changed {
  27404. *vp = v
  27405. }
  27406. return
  27407. }
  27408. fastpathTV.DecMapInt16UintV(rv2i(rv).(map[int16]uint), false, d)
  27409. }
  27410. func (f fastpathT) DecMapInt16UintX(vp *map[int16]uint, d *Decoder) {
  27411. if v, changed := f.DecMapInt16UintV(*vp, true, d); changed {
  27412. *vp = v
  27413. }
  27414. }
  27415. func (_ fastpathT) DecMapInt16UintV(v map[int16]uint, canChange bool,
  27416. d *Decoder) (_ map[int16]uint, changed bool) {
  27417. dd, esep := d.d, d.hh.hasElemSeparators()
  27418. containerLen := dd.ReadMapStart()
  27419. if canChange && v == nil {
  27420. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  27421. v = make(map[int16]uint, xlen)
  27422. changed = true
  27423. }
  27424. if containerLen == 0 {
  27425. dd.ReadMapEnd()
  27426. return v, changed
  27427. }
  27428. var mk int16
  27429. var mv uint
  27430. hasLen := containerLen > 0
  27431. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27432. if esep {
  27433. dd.ReadMapElemKey()
  27434. }
  27435. mk = int16(dd.DecodeInt(16))
  27436. if esep {
  27437. dd.ReadMapElemValue()
  27438. }
  27439. if dd.TryDecodeAsNil() {
  27440. if d.h.DeleteOnNilMapValue {
  27441. delete(v, mk)
  27442. } else {
  27443. v[mk] = 0
  27444. }
  27445. continue
  27446. }
  27447. mv = uint(dd.DecodeUint(uintBitsize))
  27448. if v != nil {
  27449. v[mk] = mv
  27450. }
  27451. }
  27452. dd.ReadMapEnd()
  27453. return v, changed
  27454. }
  27455. func (d *Decoder) fastpathDecMapInt16Uint8R(f *codecFnInfo, rv reflect.Value) {
  27456. if rv.Kind() == reflect.Ptr {
  27457. vp := rv2i(rv).(*map[int16]uint8)
  27458. if v, changed := fastpathTV.DecMapInt16Uint8V(*vp, true, d); changed {
  27459. *vp = v
  27460. }
  27461. return
  27462. }
  27463. fastpathTV.DecMapInt16Uint8V(rv2i(rv).(map[int16]uint8), false, d)
  27464. }
  27465. func (f fastpathT) DecMapInt16Uint8X(vp *map[int16]uint8, d *Decoder) {
  27466. if v, changed := f.DecMapInt16Uint8V(*vp, true, d); changed {
  27467. *vp = v
  27468. }
  27469. }
  27470. func (_ fastpathT) DecMapInt16Uint8V(v map[int16]uint8, canChange bool,
  27471. d *Decoder) (_ map[int16]uint8, changed bool) {
  27472. dd, esep := d.d, d.hh.hasElemSeparators()
  27473. containerLen := dd.ReadMapStart()
  27474. if canChange && v == nil {
  27475. xlen := decInferLen(containerLen, d.h.MaxInitLen, 3)
  27476. v = make(map[int16]uint8, xlen)
  27477. changed = true
  27478. }
  27479. if containerLen == 0 {
  27480. dd.ReadMapEnd()
  27481. return v, changed
  27482. }
  27483. var mk int16
  27484. var mv uint8
  27485. hasLen := containerLen > 0
  27486. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27487. if esep {
  27488. dd.ReadMapElemKey()
  27489. }
  27490. mk = int16(dd.DecodeInt(16))
  27491. if esep {
  27492. dd.ReadMapElemValue()
  27493. }
  27494. if dd.TryDecodeAsNil() {
  27495. if d.h.DeleteOnNilMapValue {
  27496. delete(v, mk)
  27497. } else {
  27498. v[mk] = 0
  27499. }
  27500. continue
  27501. }
  27502. mv = uint8(dd.DecodeUint(8))
  27503. if v != nil {
  27504. v[mk] = mv
  27505. }
  27506. }
  27507. dd.ReadMapEnd()
  27508. return v, changed
  27509. }
  27510. func (d *Decoder) fastpathDecMapInt16Uint16R(f *codecFnInfo, rv reflect.Value) {
  27511. if rv.Kind() == reflect.Ptr {
  27512. vp := rv2i(rv).(*map[int16]uint16)
  27513. if v, changed := fastpathTV.DecMapInt16Uint16V(*vp, true, d); changed {
  27514. *vp = v
  27515. }
  27516. return
  27517. }
  27518. fastpathTV.DecMapInt16Uint16V(rv2i(rv).(map[int16]uint16), false, d)
  27519. }
  27520. func (f fastpathT) DecMapInt16Uint16X(vp *map[int16]uint16, d *Decoder) {
  27521. if v, changed := f.DecMapInt16Uint16V(*vp, true, d); changed {
  27522. *vp = v
  27523. }
  27524. }
  27525. func (_ fastpathT) DecMapInt16Uint16V(v map[int16]uint16, canChange bool,
  27526. d *Decoder) (_ map[int16]uint16, changed bool) {
  27527. dd, esep := d.d, d.hh.hasElemSeparators()
  27528. containerLen := dd.ReadMapStart()
  27529. if canChange && v == nil {
  27530. xlen := decInferLen(containerLen, d.h.MaxInitLen, 4)
  27531. v = make(map[int16]uint16, xlen)
  27532. changed = true
  27533. }
  27534. if containerLen == 0 {
  27535. dd.ReadMapEnd()
  27536. return v, changed
  27537. }
  27538. var mk int16
  27539. var mv uint16
  27540. hasLen := containerLen > 0
  27541. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27542. if esep {
  27543. dd.ReadMapElemKey()
  27544. }
  27545. mk = int16(dd.DecodeInt(16))
  27546. if esep {
  27547. dd.ReadMapElemValue()
  27548. }
  27549. if dd.TryDecodeAsNil() {
  27550. if d.h.DeleteOnNilMapValue {
  27551. delete(v, mk)
  27552. } else {
  27553. v[mk] = 0
  27554. }
  27555. continue
  27556. }
  27557. mv = uint16(dd.DecodeUint(16))
  27558. if v != nil {
  27559. v[mk] = mv
  27560. }
  27561. }
  27562. dd.ReadMapEnd()
  27563. return v, changed
  27564. }
  27565. func (d *Decoder) fastpathDecMapInt16Uint32R(f *codecFnInfo, rv reflect.Value) {
  27566. if rv.Kind() == reflect.Ptr {
  27567. vp := rv2i(rv).(*map[int16]uint32)
  27568. if v, changed := fastpathTV.DecMapInt16Uint32V(*vp, true, d); changed {
  27569. *vp = v
  27570. }
  27571. return
  27572. }
  27573. fastpathTV.DecMapInt16Uint32V(rv2i(rv).(map[int16]uint32), false, d)
  27574. }
  27575. func (f fastpathT) DecMapInt16Uint32X(vp *map[int16]uint32, d *Decoder) {
  27576. if v, changed := f.DecMapInt16Uint32V(*vp, true, d); changed {
  27577. *vp = v
  27578. }
  27579. }
  27580. func (_ fastpathT) DecMapInt16Uint32V(v map[int16]uint32, canChange bool,
  27581. d *Decoder) (_ map[int16]uint32, changed bool) {
  27582. dd, esep := d.d, d.hh.hasElemSeparators()
  27583. containerLen := dd.ReadMapStart()
  27584. if canChange && v == nil {
  27585. xlen := decInferLen(containerLen, d.h.MaxInitLen, 6)
  27586. v = make(map[int16]uint32, xlen)
  27587. changed = true
  27588. }
  27589. if containerLen == 0 {
  27590. dd.ReadMapEnd()
  27591. return v, changed
  27592. }
  27593. var mk int16
  27594. var mv uint32
  27595. hasLen := containerLen > 0
  27596. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27597. if esep {
  27598. dd.ReadMapElemKey()
  27599. }
  27600. mk = int16(dd.DecodeInt(16))
  27601. if esep {
  27602. dd.ReadMapElemValue()
  27603. }
  27604. if dd.TryDecodeAsNil() {
  27605. if d.h.DeleteOnNilMapValue {
  27606. delete(v, mk)
  27607. } else {
  27608. v[mk] = 0
  27609. }
  27610. continue
  27611. }
  27612. mv = uint32(dd.DecodeUint(32))
  27613. if v != nil {
  27614. v[mk] = mv
  27615. }
  27616. }
  27617. dd.ReadMapEnd()
  27618. return v, changed
  27619. }
  27620. func (d *Decoder) fastpathDecMapInt16Uint64R(f *codecFnInfo, rv reflect.Value) {
  27621. if rv.Kind() == reflect.Ptr {
  27622. vp := rv2i(rv).(*map[int16]uint64)
  27623. if v, changed := fastpathTV.DecMapInt16Uint64V(*vp, true, d); changed {
  27624. *vp = v
  27625. }
  27626. return
  27627. }
  27628. fastpathTV.DecMapInt16Uint64V(rv2i(rv).(map[int16]uint64), false, d)
  27629. }
  27630. func (f fastpathT) DecMapInt16Uint64X(vp *map[int16]uint64, d *Decoder) {
  27631. if v, changed := f.DecMapInt16Uint64V(*vp, true, d); changed {
  27632. *vp = v
  27633. }
  27634. }
  27635. func (_ fastpathT) DecMapInt16Uint64V(v map[int16]uint64, canChange bool,
  27636. d *Decoder) (_ map[int16]uint64, changed bool) {
  27637. dd, esep := d.d, d.hh.hasElemSeparators()
  27638. containerLen := dd.ReadMapStart()
  27639. if canChange && v == nil {
  27640. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  27641. v = make(map[int16]uint64, xlen)
  27642. changed = true
  27643. }
  27644. if containerLen == 0 {
  27645. dd.ReadMapEnd()
  27646. return v, changed
  27647. }
  27648. var mk int16
  27649. var mv uint64
  27650. hasLen := containerLen > 0
  27651. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27652. if esep {
  27653. dd.ReadMapElemKey()
  27654. }
  27655. mk = int16(dd.DecodeInt(16))
  27656. if esep {
  27657. dd.ReadMapElemValue()
  27658. }
  27659. if dd.TryDecodeAsNil() {
  27660. if d.h.DeleteOnNilMapValue {
  27661. delete(v, mk)
  27662. } else {
  27663. v[mk] = 0
  27664. }
  27665. continue
  27666. }
  27667. mv = dd.DecodeUint(64)
  27668. if v != nil {
  27669. v[mk] = mv
  27670. }
  27671. }
  27672. dd.ReadMapEnd()
  27673. return v, changed
  27674. }
  27675. func (d *Decoder) fastpathDecMapInt16UintptrR(f *codecFnInfo, rv reflect.Value) {
  27676. if rv.Kind() == reflect.Ptr {
  27677. vp := rv2i(rv).(*map[int16]uintptr)
  27678. if v, changed := fastpathTV.DecMapInt16UintptrV(*vp, true, d); changed {
  27679. *vp = v
  27680. }
  27681. return
  27682. }
  27683. fastpathTV.DecMapInt16UintptrV(rv2i(rv).(map[int16]uintptr), false, d)
  27684. }
  27685. func (f fastpathT) DecMapInt16UintptrX(vp *map[int16]uintptr, d *Decoder) {
  27686. if v, changed := f.DecMapInt16UintptrV(*vp, true, d); changed {
  27687. *vp = v
  27688. }
  27689. }
  27690. func (_ fastpathT) DecMapInt16UintptrV(v map[int16]uintptr, canChange bool,
  27691. d *Decoder) (_ map[int16]uintptr, changed bool) {
  27692. dd, esep := d.d, d.hh.hasElemSeparators()
  27693. containerLen := dd.ReadMapStart()
  27694. if canChange && v == nil {
  27695. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  27696. v = make(map[int16]uintptr, xlen)
  27697. changed = true
  27698. }
  27699. if containerLen == 0 {
  27700. dd.ReadMapEnd()
  27701. return v, changed
  27702. }
  27703. var mk int16
  27704. var mv uintptr
  27705. hasLen := containerLen > 0
  27706. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27707. if esep {
  27708. dd.ReadMapElemKey()
  27709. }
  27710. mk = int16(dd.DecodeInt(16))
  27711. if esep {
  27712. dd.ReadMapElemValue()
  27713. }
  27714. if dd.TryDecodeAsNil() {
  27715. if d.h.DeleteOnNilMapValue {
  27716. delete(v, mk)
  27717. } else {
  27718. v[mk] = 0
  27719. }
  27720. continue
  27721. }
  27722. mv = uintptr(dd.DecodeUint(uintBitsize))
  27723. if v != nil {
  27724. v[mk] = mv
  27725. }
  27726. }
  27727. dd.ReadMapEnd()
  27728. return v, changed
  27729. }
  27730. func (d *Decoder) fastpathDecMapInt16IntR(f *codecFnInfo, rv reflect.Value) {
  27731. if rv.Kind() == reflect.Ptr {
  27732. vp := rv2i(rv).(*map[int16]int)
  27733. if v, changed := fastpathTV.DecMapInt16IntV(*vp, true, d); changed {
  27734. *vp = v
  27735. }
  27736. return
  27737. }
  27738. fastpathTV.DecMapInt16IntV(rv2i(rv).(map[int16]int), false, d)
  27739. }
  27740. func (f fastpathT) DecMapInt16IntX(vp *map[int16]int, d *Decoder) {
  27741. if v, changed := f.DecMapInt16IntV(*vp, true, d); changed {
  27742. *vp = v
  27743. }
  27744. }
  27745. func (_ fastpathT) DecMapInt16IntV(v map[int16]int, canChange bool,
  27746. d *Decoder) (_ map[int16]int, changed bool) {
  27747. dd, esep := d.d, d.hh.hasElemSeparators()
  27748. containerLen := dd.ReadMapStart()
  27749. if canChange && v == nil {
  27750. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  27751. v = make(map[int16]int, xlen)
  27752. changed = true
  27753. }
  27754. if containerLen == 0 {
  27755. dd.ReadMapEnd()
  27756. return v, changed
  27757. }
  27758. var mk int16
  27759. var mv int
  27760. hasLen := containerLen > 0
  27761. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27762. if esep {
  27763. dd.ReadMapElemKey()
  27764. }
  27765. mk = int16(dd.DecodeInt(16))
  27766. if esep {
  27767. dd.ReadMapElemValue()
  27768. }
  27769. if dd.TryDecodeAsNil() {
  27770. if d.h.DeleteOnNilMapValue {
  27771. delete(v, mk)
  27772. } else {
  27773. v[mk] = 0
  27774. }
  27775. continue
  27776. }
  27777. mv = int(dd.DecodeInt(intBitsize))
  27778. if v != nil {
  27779. v[mk] = mv
  27780. }
  27781. }
  27782. dd.ReadMapEnd()
  27783. return v, changed
  27784. }
  27785. func (d *Decoder) fastpathDecMapInt16Int8R(f *codecFnInfo, rv reflect.Value) {
  27786. if rv.Kind() == reflect.Ptr {
  27787. vp := rv2i(rv).(*map[int16]int8)
  27788. if v, changed := fastpathTV.DecMapInt16Int8V(*vp, true, d); changed {
  27789. *vp = v
  27790. }
  27791. return
  27792. }
  27793. fastpathTV.DecMapInt16Int8V(rv2i(rv).(map[int16]int8), false, d)
  27794. }
  27795. func (f fastpathT) DecMapInt16Int8X(vp *map[int16]int8, d *Decoder) {
  27796. if v, changed := f.DecMapInt16Int8V(*vp, true, d); changed {
  27797. *vp = v
  27798. }
  27799. }
  27800. func (_ fastpathT) DecMapInt16Int8V(v map[int16]int8, canChange bool,
  27801. d *Decoder) (_ map[int16]int8, changed bool) {
  27802. dd, esep := d.d, d.hh.hasElemSeparators()
  27803. containerLen := dd.ReadMapStart()
  27804. if canChange && v == nil {
  27805. xlen := decInferLen(containerLen, d.h.MaxInitLen, 3)
  27806. v = make(map[int16]int8, xlen)
  27807. changed = true
  27808. }
  27809. if containerLen == 0 {
  27810. dd.ReadMapEnd()
  27811. return v, changed
  27812. }
  27813. var mk int16
  27814. var mv int8
  27815. hasLen := containerLen > 0
  27816. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27817. if esep {
  27818. dd.ReadMapElemKey()
  27819. }
  27820. mk = int16(dd.DecodeInt(16))
  27821. if esep {
  27822. dd.ReadMapElemValue()
  27823. }
  27824. if dd.TryDecodeAsNil() {
  27825. if d.h.DeleteOnNilMapValue {
  27826. delete(v, mk)
  27827. } else {
  27828. v[mk] = 0
  27829. }
  27830. continue
  27831. }
  27832. mv = int8(dd.DecodeInt(8))
  27833. if v != nil {
  27834. v[mk] = mv
  27835. }
  27836. }
  27837. dd.ReadMapEnd()
  27838. return v, changed
  27839. }
  27840. func (d *Decoder) fastpathDecMapInt16Int16R(f *codecFnInfo, rv reflect.Value) {
  27841. if rv.Kind() == reflect.Ptr {
  27842. vp := rv2i(rv).(*map[int16]int16)
  27843. if v, changed := fastpathTV.DecMapInt16Int16V(*vp, true, d); changed {
  27844. *vp = v
  27845. }
  27846. return
  27847. }
  27848. fastpathTV.DecMapInt16Int16V(rv2i(rv).(map[int16]int16), false, d)
  27849. }
  27850. func (f fastpathT) DecMapInt16Int16X(vp *map[int16]int16, d *Decoder) {
  27851. if v, changed := f.DecMapInt16Int16V(*vp, true, d); changed {
  27852. *vp = v
  27853. }
  27854. }
  27855. func (_ fastpathT) DecMapInt16Int16V(v map[int16]int16, canChange bool,
  27856. d *Decoder) (_ map[int16]int16, changed bool) {
  27857. dd, esep := d.d, d.hh.hasElemSeparators()
  27858. containerLen := dd.ReadMapStart()
  27859. if canChange && v == nil {
  27860. xlen := decInferLen(containerLen, d.h.MaxInitLen, 4)
  27861. v = make(map[int16]int16, xlen)
  27862. changed = true
  27863. }
  27864. if containerLen == 0 {
  27865. dd.ReadMapEnd()
  27866. return v, changed
  27867. }
  27868. var mk int16
  27869. var mv int16
  27870. hasLen := containerLen > 0
  27871. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27872. if esep {
  27873. dd.ReadMapElemKey()
  27874. }
  27875. mk = int16(dd.DecodeInt(16))
  27876. if esep {
  27877. dd.ReadMapElemValue()
  27878. }
  27879. if dd.TryDecodeAsNil() {
  27880. if d.h.DeleteOnNilMapValue {
  27881. delete(v, mk)
  27882. } else {
  27883. v[mk] = 0
  27884. }
  27885. continue
  27886. }
  27887. mv = int16(dd.DecodeInt(16))
  27888. if v != nil {
  27889. v[mk] = mv
  27890. }
  27891. }
  27892. dd.ReadMapEnd()
  27893. return v, changed
  27894. }
  27895. func (d *Decoder) fastpathDecMapInt16Int32R(f *codecFnInfo, rv reflect.Value) {
  27896. if rv.Kind() == reflect.Ptr {
  27897. vp := rv2i(rv).(*map[int16]int32)
  27898. if v, changed := fastpathTV.DecMapInt16Int32V(*vp, true, d); changed {
  27899. *vp = v
  27900. }
  27901. return
  27902. }
  27903. fastpathTV.DecMapInt16Int32V(rv2i(rv).(map[int16]int32), false, d)
  27904. }
  27905. func (f fastpathT) DecMapInt16Int32X(vp *map[int16]int32, d *Decoder) {
  27906. if v, changed := f.DecMapInt16Int32V(*vp, true, d); changed {
  27907. *vp = v
  27908. }
  27909. }
  27910. func (_ fastpathT) DecMapInt16Int32V(v map[int16]int32, canChange bool,
  27911. d *Decoder) (_ map[int16]int32, changed bool) {
  27912. dd, esep := d.d, d.hh.hasElemSeparators()
  27913. containerLen := dd.ReadMapStart()
  27914. if canChange && v == nil {
  27915. xlen := decInferLen(containerLen, d.h.MaxInitLen, 6)
  27916. v = make(map[int16]int32, xlen)
  27917. changed = true
  27918. }
  27919. if containerLen == 0 {
  27920. dd.ReadMapEnd()
  27921. return v, changed
  27922. }
  27923. var mk int16
  27924. var mv int32
  27925. hasLen := containerLen > 0
  27926. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27927. if esep {
  27928. dd.ReadMapElemKey()
  27929. }
  27930. mk = int16(dd.DecodeInt(16))
  27931. if esep {
  27932. dd.ReadMapElemValue()
  27933. }
  27934. if dd.TryDecodeAsNil() {
  27935. if d.h.DeleteOnNilMapValue {
  27936. delete(v, mk)
  27937. } else {
  27938. v[mk] = 0
  27939. }
  27940. continue
  27941. }
  27942. mv = int32(dd.DecodeInt(32))
  27943. if v != nil {
  27944. v[mk] = mv
  27945. }
  27946. }
  27947. dd.ReadMapEnd()
  27948. return v, changed
  27949. }
  27950. func (d *Decoder) fastpathDecMapInt16Int64R(f *codecFnInfo, rv reflect.Value) {
  27951. if rv.Kind() == reflect.Ptr {
  27952. vp := rv2i(rv).(*map[int16]int64)
  27953. if v, changed := fastpathTV.DecMapInt16Int64V(*vp, true, d); changed {
  27954. *vp = v
  27955. }
  27956. return
  27957. }
  27958. fastpathTV.DecMapInt16Int64V(rv2i(rv).(map[int16]int64), false, d)
  27959. }
  27960. func (f fastpathT) DecMapInt16Int64X(vp *map[int16]int64, d *Decoder) {
  27961. if v, changed := f.DecMapInt16Int64V(*vp, true, d); changed {
  27962. *vp = v
  27963. }
  27964. }
  27965. func (_ fastpathT) DecMapInt16Int64V(v map[int16]int64, canChange bool,
  27966. d *Decoder) (_ map[int16]int64, changed bool) {
  27967. dd, esep := d.d, d.hh.hasElemSeparators()
  27968. containerLen := dd.ReadMapStart()
  27969. if canChange && v == nil {
  27970. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  27971. v = make(map[int16]int64, xlen)
  27972. changed = true
  27973. }
  27974. if containerLen == 0 {
  27975. dd.ReadMapEnd()
  27976. return v, changed
  27977. }
  27978. var mk int16
  27979. var mv int64
  27980. hasLen := containerLen > 0
  27981. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27982. if esep {
  27983. dd.ReadMapElemKey()
  27984. }
  27985. mk = int16(dd.DecodeInt(16))
  27986. if esep {
  27987. dd.ReadMapElemValue()
  27988. }
  27989. if dd.TryDecodeAsNil() {
  27990. if d.h.DeleteOnNilMapValue {
  27991. delete(v, mk)
  27992. } else {
  27993. v[mk] = 0
  27994. }
  27995. continue
  27996. }
  27997. mv = dd.DecodeInt(64)
  27998. if v != nil {
  27999. v[mk] = mv
  28000. }
  28001. }
  28002. dd.ReadMapEnd()
  28003. return v, changed
  28004. }
  28005. func (d *Decoder) fastpathDecMapInt16Float32R(f *codecFnInfo, rv reflect.Value) {
  28006. if rv.Kind() == reflect.Ptr {
  28007. vp := rv2i(rv).(*map[int16]float32)
  28008. if v, changed := fastpathTV.DecMapInt16Float32V(*vp, true, d); changed {
  28009. *vp = v
  28010. }
  28011. return
  28012. }
  28013. fastpathTV.DecMapInt16Float32V(rv2i(rv).(map[int16]float32), false, d)
  28014. }
  28015. func (f fastpathT) DecMapInt16Float32X(vp *map[int16]float32, d *Decoder) {
  28016. if v, changed := f.DecMapInt16Float32V(*vp, true, d); changed {
  28017. *vp = v
  28018. }
  28019. }
  28020. func (_ fastpathT) DecMapInt16Float32V(v map[int16]float32, canChange bool,
  28021. d *Decoder) (_ map[int16]float32, changed bool) {
  28022. dd, esep := d.d, d.hh.hasElemSeparators()
  28023. containerLen := dd.ReadMapStart()
  28024. if canChange && v == nil {
  28025. xlen := decInferLen(containerLen, d.h.MaxInitLen, 6)
  28026. v = make(map[int16]float32, xlen)
  28027. changed = true
  28028. }
  28029. if containerLen == 0 {
  28030. dd.ReadMapEnd()
  28031. return v, changed
  28032. }
  28033. var mk int16
  28034. var mv float32
  28035. hasLen := containerLen > 0
  28036. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28037. if esep {
  28038. dd.ReadMapElemKey()
  28039. }
  28040. mk = int16(dd.DecodeInt(16))
  28041. if esep {
  28042. dd.ReadMapElemValue()
  28043. }
  28044. if dd.TryDecodeAsNil() {
  28045. if d.h.DeleteOnNilMapValue {
  28046. delete(v, mk)
  28047. } else {
  28048. v[mk] = 0
  28049. }
  28050. continue
  28051. }
  28052. mv = float32(dd.DecodeFloat(true))
  28053. if v != nil {
  28054. v[mk] = mv
  28055. }
  28056. }
  28057. dd.ReadMapEnd()
  28058. return v, changed
  28059. }
  28060. func (d *Decoder) fastpathDecMapInt16Float64R(f *codecFnInfo, rv reflect.Value) {
  28061. if rv.Kind() == reflect.Ptr {
  28062. vp := rv2i(rv).(*map[int16]float64)
  28063. if v, changed := fastpathTV.DecMapInt16Float64V(*vp, true, d); changed {
  28064. *vp = v
  28065. }
  28066. return
  28067. }
  28068. fastpathTV.DecMapInt16Float64V(rv2i(rv).(map[int16]float64), false, d)
  28069. }
  28070. func (f fastpathT) DecMapInt16Float64X(vp *map[int16]float64, d *Decoder) {
  28071. if v, changed := f.DecMapInt16Float64V(*vp, true, d); changed {
  28072. *vp = v
  28073. }
  28074. }
  28075. func (_ fastpathT) DecMapInt16Float64V(v map[int16]float64, canChange bool,
  28076. d *Decoder) (_ map[int16]float64, changed bool) {
  28077. dd, esep := d.d, d.hh.hasElemSeparators()
  28078. containerLen := dd.ReadMapStart()
  28079. if canChange && v == nil {
  28080. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  28081. v = make(map[int16]float64, xlen)
  28082. changed = true
  28083. }
  28084. if containerLen == 0 {
  28085. dd.ReadMapEnd()
  28086. return v, changed
  28087. }
  28088. var mk int16
  28089. var mv float64
  28090. hasLen := containerLen > 0
  28091. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28092. if esep {
  28093. dd.ReadMapElemKey()
  28094. }
  28095. mk = int16(dd.DecodeInt(16))
  28096. if esep {
  28097. dd.ReadMapElemValue()
  28098. }
  28099. if dd.TryDecodeAsNil() {
  28100. if d.h.DeleteOnNilMapValue {
  28101. delete(v, mk)
  28102. } else {
  28103. v[mk] = 0
  28104. }
  28105. continue
  28106. }
  28107. mv = dd.DecodeFloat(false)
  28108. if v != nil {
  28109. v[mk] = mv
  28110. }
  28111. }
  28112. dd.ReadMapEnd()
  28113. return v, changed
  28114. }
  28115. func (d *Decoder) fastpathDecMapInt16BoolR(f *codecFnInfo, rv reflect.Value) {
  28116. if rv.Kind() == reflect.Ptr {
  28117. vp := rv2i(rv).(*map[int16]bool)
  28118. if v, changed := fastpathTV.DecMapInt16BoolV(*vp, true, d); changed {
  28119. *vp = v
  28120. }
  28121. return
  28122. }
  28123. fastpathTV.DecMapInt16BoolV(rv2i(rv).(map[int16]bool), false, d)
  28124. }
  28125. func (f fastpathT) DecMapInt16BoolX(vp *map[int16]bool, d *Decoder) {
  28126. if v, changed := f.DecMapInt16BoolV(*vp, true, d); changed {
  28127. *vp = v
  28128. }
  28129. }
  28130. func (_ fastpathT) DecMapInt16BoolV(v map[int16]bool, canChange bool,
  28131. d *Decoder) (_ map[int16]bool, changed bool) {
  28132. dd, esep := d.d, d.hh.hasElemSeparators()
  28133. containerLen := dd.ReadMapStart()
  28134. if canChange && v == nil {
  28135. xlen := decInferLen(containerLen, d.h.MaxInitLen, 3)
  28136. v = make(map[int16]bool, xlen)
  28137. changed = true
  28138. }
  28139. if containerLen == 0 {
  28140. dd.ReadMapEnd()
  28141. return v, changed
  28142. }
  28143. var mk int16
  28144. var mv bool
  28145. hasLen := containerLen > 0
  28146. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28147. if esep {
  28148. dd.ReadMapElemKey()
  28149. }
  28150. mk = int16(dd.DecodeInt(16))
  28151. if esep {
  28152. dd.ReadMapElemValue()
  28153. }
  28154. if dd.TryDecodeAsNil() {
  28155. if d.h.DeleteOnNilMapValue {
  28156. delete(v, mk)
  28157. } else {
  28158. v[mk] = false
  28159. }
  28160. continue
  28161. }
  28162. mv = dd.DecodeBool()
  28163. if v != nil {
  28164. v[mk] = mv
  28165. }
  28166. }
  28167. dd.ReadMapEnd()
  28168. return v, changed
  28169. }
  28170. func (d *Decoder) fastpathDecMapInt32IntfR(f *codecFnInfo, rv reflect.Value) {
  28171. if rv.Kind() == reflect.Ptr {
  28172. vp := rv2i(rv).(*map[int32]interface{})
  28173. if v, changed := fastpathTV.DecMapInt32IntfV(*vp, true, d); changed {
  28174. *vp = v
  28175. }
  28176. return
  28177. }
  28178. fastpathTV.DecMapInt32IntfV(rv2i(rv).(map[int32]interface{}), false, d)
  28179. }
  28180. func (f fastpathT) DecMapInt32IntfX(vp *map[int32]interface{}, d *Decoder) {
  28181. if v, changed := f.DecMapInt32IntfV(*vp, true, d); changed {
  28182. *vp = v
  28183. }
  28184. }
  28185. func (_ fastpathT) DecMapInt32IntfV(v map[int32]interface{}, canChange bool,
  28186. d *Decoder) (_ map[int32]interface{}, changed bool) {
  28187. dd, esep := d.d, d.hh.hasElemSeparators()
  28188. containerLen := dd.ReadMapStart()
  28189. if canChange && v == nil {
  28190. xlen := decInferLen(containerLen, d.h.MaxInitLen, 20)
  28191. v = make(map[int32]interface{}, xlen)
  28192. changed = true
  28193. }
  28194. if containerLen == 0 {
  28195. dd.ReadMapEnd()
  28196. return v, changed
  28197. }
  28198. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  28199. var mk int32
  28200. var mv interface{}
  28201. hasLen := containerLen > 0
  28202. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28203. if esep {
  28204. dd.ReadMapElemKey()
  28205. }
  28206. mk = int32(dd.DecodeInt(32))
  28207. if esep {
  28208. dd.ReadMapElemValue()
  28209. }
  28210. if dd.TryDecodeAsNil() {
  28211. if d.h.DeleteOnNilMapValue {
  28212. delete(v, mk)
  28213. } else {
  28214. v[mk] = nil
  28215. }
  28216. continue
  28217. }
  28218. if mapGet {
  28219. mv = v[mk]
  28220. } else {
  28221. mv = nil
  28222. }
  28223. d.decode(&mv)
  28224. if v != nil {
  28225. v[mk] = mv
  28226. }
  28227. }
  28228. dd.ReadMapEnd()
  28229. return v, changed
  28230. }
  28231. func (d *Decoder) fastpathDecMapInt32StringR(f *codecFnInfo, rv reflect.Value) {
  28232. if rv.Kind() == reflect.Ptr {
  28233. vp := rv2i(rv).(*map[int32]string)
  28234. if v, changed := fastpathTV.DecMapInt32StringV(*vp, true, d); changed {
  28235. *vp = v
  28236. }
  28237. return
  28238. }
  28239. fastpathTV.DecMapInt32StringV(rv2i(rv).(map[int32]string), false, d)
  28240. }
  28241. func (f fastpathT) DecMapInt32StringX(vp *map[int32]string, d *Decoder) {
  28242. if v, changed := f.DecMapInt32StringV(*vp, true, d); changed {
  28243. *vp = v
  28244. }
  28245. }
  28246. func (_ fastpathT) DecMapInt32StringV(v map[int32]string, canChange bool,
  28247. d *Decoder) (_ map[int32]string, changed bool) {
  28248. dd, esep := d.d, d.hh.hasElemSeparators()
  28249. containerLen := dd.ReadMapStart()
  28250. if canChange && v == nil {
  28251. xlen := decInferLen(containerLen, d.h.MaxInitLen, 20)
  28252. v = make(map[int32]string, xlen)
  28253. changed = true
  28254. }
  28255. if containerLen == 0 {
  28256. dd.ReadMapEnd()
  28257. return v, changed
  28258. }
  28259. var mk int32
  28260. var mv string
  28261. hasLen := containerLen > 0
  28262. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28263. if esep {
  28264. dd.ReadMapElemKey()
  28265. }
  28266. mk = int32(dd.DecodeInt(32))
  28267. if esep {
  28268. dd.ReadMapElemValue()
  28269. }
  28270. if dd.TryDecodeAsNil() {
  28271. if d.h.DeleteOnNilMapValue {
  28272. delete(v, mk)
  28273. } else {
  28274. v[mk] = ""
  28275. }
  28276. continue
  28277. }
  28278. mv = dd.DecodeString()
  28279. if v != nil {
  28280. v[mk] = mv
  28281. }
  28282. }
  28283. dd.ReadMapEnd()
  28284. return v, changed
  28285. }
  28286. func (d *Decoder) fastpathDecMapInt32UintR(f *codecFnInfo, rv reflect.Value) {
  28287. if rv.Kind() == reflect.Ptr {
  28288. vp := rv2i(rv).(*map[int32]uint)
  28289. if v, changed := fastpathTV.DecMapInt32UintV(*vp, true, d); changed {
  28290. *vp = v
  28291. }
  28292. return
  28293. }
  28294. fastpathTV.DecMapInt32UintV(rv2i(rv).(map[int32]uint), false, d)
  28295. }
  28296. func (f fastpathT) DecMapInt32UintX(vp *map[int32]uint, d *Decoder) {
  28297. if v, changed := f.DecMapInt32UintV(*vp, true, d); changed {
  28298. *vp = v
  28299. }
  28300. }
  28301. func (_ fastpathT) DecMapInt32UintV(v map[int32]uint, canChange bool,
  28302. d *Decoder) (_ map[int32]uint, changed bool) {
  28303. dd, esep := d.d, d.hh.hasElemSeparators()
  28304. containerLen := dd.ReadMapStart()
  28305. if canChange && v == nil {
  28306. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  28307. v = make(map[int32]uint, xlen)
  28308. changed = true
  28309. }
  28310. if containerLen == 0 {
  28311. dd.ReadMapEnd()
  28312. return v, changed
  28313. }
  28314. var mk int32
  28315. var mv uint
  28316. hasLen := containerLen > 0
  28317. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28318. if esep {
  28319. dd.ReadMapElemKey()
  28320. }
  28321. mk = int32(dd.DecodeInt(32))
  28322. if esep {
  28323. dd.ReadMapElemValue()
  28324. }
  28325. if dd.TryDecodeAsNil() {
  28326. if d.h.DeleteOnNilMapValue {
  28327. delete(v, mk)
  28328. } else {
  28329. v[mk] = 0
  28330. }
  28331. continue
  28332. }
  28333. mv = uint(dd.DecodeUint(uintBitsize))
  28334. if v != nil {
  28335. v[mk] = mv
  28336. }
  28337. }
  28338. dd.ReadMapEnd()
  28339. return v, changed
  28340. }
  28341. func (d *Decoder) fastpathDecMapInt32Uint8R(f *codecFnInfo, rv reflect.Value) {
  28342. if rv.Kind() == reflect.Ptr {
  28343. vp := rv2i(rv).(*map[int32]uint8)
  28344. if v, changed := fastpathTV.DecMapInt32Uint8V(*vp, true, d); changed {
  28345. *vp = v
  28346. }
  28347. return
  28348. }
  28349. fastpathTV.DecMapInt32Uint8V(rv2i(rv).(map[int32]uint8), false, d)
  28350. }
  28351. func (f fastpathT) DecMapInt32Uint8X(vp *map[int32]uint8, d *Decoder) {
  28352. if v, changed := f.DecMapInt32Uint8V(*vp, true, d); changed {
  28353. *vp = v
  28354. }
  28355. }
  28356. func (_ fastpathT) DecMapInt32Uint8V(v map[int32]uint8, canChange bool,
  28357. d *Decoder) (_ map[int32]uint8, changed bool) {
  28358. dd, esep := d.d, d.hh.hasElemSeparators()
  28359. containerLen := dd.ReadMapStart()
  28360. if canChange && v == nil {
  28361. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  28362. v = make(map[int32]uint8, xlen)
  28363. changed = true
  28364. }
  28365. if containerLen == 0 {
  28366. dd.ReadMapEnd()
  28367. return v, changed
  28368. }
  28369. var mk int32
  28370. var mv uint8
  28371. hasLen := containerLen > 0
  28372. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28373. if esep {
  28374. dd.ReadMapElemKey()
  28375. }
  28376. mk = int32(dd.DecodeInt(32))
  28377. if esep {
  28378. dd.ReadMapElemValue()
  28379. }
  28380. if dd.TryDecodeAsNil() {
  28381. if d.h.DeleteOnNilMapValue {
  28382. delete(v, mk)
  28383. } else {
  28384. v[mk] = 0
  28385. }
  28386. continue
  28387. }
  28388. mv = uint8(dd.DecodeUint(8))
  28389. if v != nil {
  28390. v[mk] = mv
  28391. }
  28392. }
  28393. dd.ReadMapEnd()
  28394. return v, changed
  28395. }
  28396. func (d *Decoder) fastpathDecMapInt32Uint16R(f *codecFnInfo, rv reflect.Value) {
  28397. if rv.Kind() == reflect.Ptr {
  28398. vp := rv2i(rv).(*map[int32]uint16)
  28399. if v, changed := fastpathTV.DecMapInt32Uint16V(*vp, true, d); changed {
  28400. *vp = v
  28401. }
  28402. return
  28403. }
  28404. fastpathTV.DecMapInt32Uint16V(rv2i(rv).(map[int32]uint16), false, d)
  28405. }
  28406. func (f fastpathT) DecMapInt32Uint16X(vp *map[int32]uint16, d *Decoder) {
  28407. if v, changed := f.DecMapInt32Uint16V(*vp, true, d); changed {
  28408. *vp = v
  28409. }
  28410. }
  28411. func (_ fastpathT) DecMapInt32Uint16V(v map[int32]uint16, canChange bool,
  28412. d *Decoder) (_ map[int32]uint16, changed bool) {
  28413. dd, esep := d.d, d.hh.hasElemSeparators()
  28414. containerLen := dd.ReadMapStart()
  28415. if canChange && v == nil {
  28416. xlen := decInferLen(containerLen, d.h.MaxInitLen, 6)
  28417. v = make(map[int32]uint16, xlen)
  28418. changed = true
  28419. }
  28420. if containerLen == 0 {
  28421. dd.ReadMapEnd()
  28422. return v, changed
  28423. }
  28424. var mk int32
  28425. var mv uint16
  28426. hasLen := containerLen > 0
  28427. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28428. if esep {
  28429. dd.ReadMapElemKey()
  28430. }
  28431. mk = int32(dd.DecodeInt(32))
  28432. if esep {
  28433. dd.ReadMapElemValue()
  28434. }
  28435. if dd.TryDecodeAsNil() {
  28436. if d.h.DeleteOnNilMapValue {
  28437. delete(v, mk)
  28438. } else {
  28439. v[mk] = 0
  28440. }
  28441. continue
  28442. }
  28443. mv = uint16(dd.DecodeUint(16))
  28444. if v != nil {
  28445. v[mk] = mv
  28446. }
  28447. }
  28448. dd.ReadMapEnd()
  28449. return v, changed
  28450. }
  28451. func (d *Decoder) fastpathDecMapInt32Uint32R(f *codecFnInfo, rv reflect.Value) {
  28452. if rv.Kind() == reflect.Ptr {
  28453. vp := rv2i(rv).(*map[int32]uint32)
  28454. if v, changed := fastpathTV.DecMapInt32Uint32V(*vp, true, d); changed {
  28455. *vp = v
  28456. }
  28457. return
  28458. }
  28459. fastpathTV.DecMapInt32Uint32V(rv2i(rv).(map[int32]uint32), false, d)
  28460. }
  28461. func (f fastpathT) DecMapInt32Uint32X(vp *map[int32]uint32, d *Decoder) {
  28462. if v, changed := f.DecMapInt32Uint32V(*vp, true, d); changed {
  28463. *vp = v
  28464. }
  28465. }
  28466. func (_ fastpathT) DecMapInt32Uint32V(v map[int32]uint32, canChange bool,
  28467. d *Decoder) (_ map[int32]uint32, changed bool) {
  28468. dd, esep := d.d, d.hh.hasElemSeparators()
  28469. containerLen := dd.ReadMapStart()
  28470. if canChange && v == nil {
  28471. xlen := decInferLen(containerLen, d.h.MaxInitLen, 8)
  28472. v = make(map[int32]uint32, xlen)
  28473. changed = true
  28474. }
  28475. if containerLen == 0 {
  28476. dd.ReadMapEnd()
  28477. return v, changed
  28478. }
  28479. var mk int32
  28480. var mv uint32
  28481. hasLen := containerLen > 0
  28482. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28483. if esep {
  28484. dd.ReadMapElemKey()
  28485. }
  28486. mk = int32(dd.DecodeInt(32))
  28487. if esep {
  28488. dd.ReadMapElemValue()
  28489. }
  28490. if dd.TryDecodeAsNil() {
  28491. if d.h.DeleteOnNilMapValue {
  28492. delete(v, mk)
  28493. } else {
  28494. v[mk] = 0
  28495. }
  28496. continue
  28497. }
  28498. mv = uint32(dd.DecodeUint(32))
  28499. if v != nil {
  28500. v[mk] = mv
  28501. }
  28502. }
  28503. dd.ReadMapEnd()
  28504. return v, changed
  28505. }
  28506. func (d *Decoder) fastpathDecMapInt32Uint64R(f *codecFnInfo, rv reflect.Value) {
  28507. if rv.Kind() == reflect.Ptr {
  28508. vp := rv2i(rv).(*map[int32]uint64)
  28509. if v, changed := fastpathTV.DecMapInt32Uint64V(*vp, true, d); changed {
  28510. *vp = v
  28511. }
  28512. return
  28513. }
  28514. fastpathTV.DecMapInt32Uint64V(rv2i(rv).(map[int32]uint64), false, d)
  28515. }
  28516. func (f fastpathT) DecMapInt32Uint64X(vp *map[int32]uint64, d *Decoder) {
  28517. if v, changed := f.DecMapInt32Uint64V(*vp, true, d); changed {
  28518. *vp = v
  28519. }
  28520. }
  28521. func (_ fastpathT) DecMapInt32Uint64V(v map[int32]uint64, canChange bool,
  28522. d *Decoder) (_ map[int32]uint64, changed bool) {
  28523. dd, esep := d.d, d.hh.hasElemSeparators()
  28524. containerLen := dd.ReadMapStart()
  28525. if canChange && v == nil {
  28526. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  28527. v = make(map[int32]uint64, xlen)
  28528. changed = true
  28529. }
  28530. if containerLen == 0 {
  28531. dd.ReadMapEnd()
  28532. return v, changed
  28533. }
  28534. var mk int32
  28535. var mv uint64
  28536. hasLen := containerLen > 0
  28537. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28538. if esep {
  28539. dd.ReadMapElemKey()
  28540. }
  28541. mk = int32(dd.DecodeInt(32))
  28542. if esep {
  28543. dd.ReadMapElemValue()
  28544. }
  28545. if dd.TryDecodeAsNil() {
  28546. if d.h.DeleteOnNilMapValue {
  28547. delete(v, mk)
  28548. } else {
  28549. v[mk] = 0
  28550. }
  28551. continue
  28552. }
  28553. mv = dd.DecodeUint(64)
  28554. if v != nil {
  28555. v[mk] = mv
  28556. }
  28557. }
  28558. dd.ReadMapEnd()
  28559. return v, changed
  28560. }
  28561. func (d *Decoder) fastpathDecMapInt32UintptrR(f *codecFnInfo, rv reflect.Value) {
  28562. if rv.Kind() == reflect.Ptr {
  28563. vp := rv2i(rv).(*map[int32]uintptr)
  28564. if v, changed := fastpathTV.DecMapInt32UintptrV(*vp, true, d); changed {
  28565. *vp = v
  28566. }
  28567. return
  28568. }
  28569. fastpathTV.DecMapInt32UintptrV(rv2i(rv).(map[int32]uintptr), false, d)
  28570. }
  28571. func (f fastpathT) DecMapInt32UintptrX(vp *map[int32]uintptr, d *Decoder) {
  28572. if v, changed := f.DecMapInt32UintptrV(*vp, true, d); changed {
  28573. *vp = v
  28574. }
  28575. }
  28576. func (_ fastpathT) DecMapInt32UintptrV(v map[int32]uintptr, canChange bool,
  28577. d *Decoder) (_ map[int32]uintptr, changed bool) {
  28578. dd, esep := d.d, d.hh.hasElemSeparators()
  28579. containerLen := dd.ReadMapStart()
  28580. if canChange && v == nil {
  28581. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  28582. v = make(map[int32]uintptr, xlen)
  28583. changed = true
  28584. }
  28585. if containerLen == 0 {
  28586. dd.ReadMapEnd()
  28587. return v, changed
  28588. }
  28589. var mk int32
  28590. var mv uintptr
  28591. hasLen := containerLen > 0
  28592. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28593. if esep {
  28594. dd.ReadMapElemKey()
  28595. }
  28596. mk = int32(dd.DecodeInt(32))
  28597. if esep {
  28598. dd.ReadMapElemValue()
  28599. }
  28600. if dd.TryDecodeAsNil() {
  28601. if d.h.DeleteOnNilMapValue {
  28602. delete(v, mk)
  28603. } else {
  28604. v[mk] = 0
  28605. }
  28606. continue
  28607. }
  28608. mv = uintptr(dd.DecodeUint(uintBitsize))
  28609. if v != nil {
  28610. v[mk] = mv
  28611. }
  28612. }
  28613. dd.ReadMapEnd()
  28614. return v, changed
  28615. }
  28616. func (d *Decoder) fastpathDecMapInt32IntR(f *codecFnInfo, rv reflect.Value) {
  28617. if rv.Kind() == reflect.Ptr {
  28618. vp := rv2i(rv).(*map[int32]int)
  28619. if v, changed := fastpathTV.DecMapInt32IntV(*vp, true, d); changed {
  28620. *vp = v
  28621. }
  28622. return
  28623. }
  28624. fastpathTV.DecMapInt32IntV(rv2i(rv).(map[int32]int), false, d)
  28625. }
  28626. func (f fastpathT) DecMapInt32IntX(vp *map[int32]int, d *Decoder) {
  28627. if v, changed := f.DecMapInt32IntV(*vp, true, d); changed {
  28628. *vp = v
  28629. }
  28630. }
  28631. func (_ fastpathT) DecMapInt32IntV(v map[int32]int, canChange bool,
  28632. d *Decoder) (_ map[int32]int, changed bool) {
  28633. dd, esep := d.d, d.hh.hasElemSeparators()
  28634. containerLen := dd.ReadMapStart()
  28635. if canChange && v == nil {
  28636. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  28637. v = make(map[int32]int, xlen)
  28638. changed = true
  28639. }
  28640. if containerLen == 0 {
  28641. dd.ReadMapEnd()
  28642. return v, changed
  28643. }
  28644. var mk int32
  28645. var mv int
  28646. hasLen := containerLen > 0
  28647. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28648. if esep {
  28649. dd.ReadMapElemKey()
  28650. }
  28651. mk = int32(dd.DecodeInt(32))
  28652. if esep {
  28653. dd.ReadMapElemValue()
  28654. }
  28655. if dd.TryDecodeAsNil() {
  28656. if d.h.DeleteOnNilMapValue {
  28657. delete(v, mk)
  28658. } else {
  28659. v[mk] = 0
  28660. }
  28661. continue
  28662. }
  28663. mv = int(dd.DecodeInt(intBitsize))
  28664. if v != nil {
  28665. v[mk] = mv
  28666. }
  28667. }
  28668. dd.ReadMapEnd()
  28669. return v, changed
  28670. }
  28671. func (d *Decoder) fastpathDecMapInt32Int8R(f *codecFnInfo, rv reflect.Value) {
  28672. if rv.Kind() == reflect.Ptr {
  28673. vp := rv2i(rv).(*map[int32]int8)
  28674. if v, changed := fastpathTV.DecMapInt32Int8V(*vp, true, d); changed {
  28675. *vp = v
  28676. }
  28677. return
  28678. }
  28679. fastpathTV.DecMapInt32Int8V(rv2i(rv).(map[int32]int8), false, d)
  28680. }
  28681. func (f fastpathT) DecMapInt32Int8X(vp *map[int32]int8, d *Decoder) {
  28682. if v, changed := f.DecMapInt32Int8V(*vp, true, d); changed {
  28683. *vp = v
  28684. }
  28685. }
  28686. func (_ fastpathT) DecMapInt32Int8V(v map[int32]int8, canChange bool,
  28687. d *Decoder) (_ map[int32]int8, changed bool) {
  28688. dd, esep := d.d, d.hh.hasElemSeparators()
  28689. containerLen := dd.ReadMapStart()
  28690. if canChange && v == nil {
  28691. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  28692. v = make(map[int32]int8, xlen)
  28693. changed = true
  28694. }
  28695. if containerLen == 0 {
  28696. dd.ReadMapEnd()
  28697. return v, changed
  28698. }
  28699. var mk int32
  28700. var mv int8
  28701. hasLen := containerLen > 0
  28702. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28703. if esep {
  28704. dd.ReadMapElemKey()
  28705. }
  28706. mk = int32(dd.DecodeInt(32))
  28707. if esep {
  28708. dd.ReadMapElemValue()
  28709. }
  28710. if dd.TryDecodeAsNil() {
  28711. if d.h.DeleteOnNilMapValue {
  28712. delete(v, mk)
  28713. } else {
  28714. v[mk] = 0
  28715. }
  28716. continue
  28717. }
  28718. mv = int8(dd.DecodeInt(8))
  28719. if v != nil {
  28720. v[mk] = mv
  28721. }
  28722. }
  28723. dd.ReadMapEnd()
  28724. return v, changed
  28725. }
  28726. func (d *Decoder) fastpathDecMapInt32Int16R(f *codecFnInfo, rv reflect.Value) {
  28727. if rv.Kind() == reflect.Ptr {
  28728. vp := rv2i(rv).(*map[int32]int16)
  28729. if v, changed := fastpathTV.DecMapInt32Int16V(*vp, true, d); changed {
  28730. *vp = v
  28731. }
  28732. return
  28733. }
  28734. fastpathTV.DecMapInt32Int16V(rv2i(rv).(map[int32]int16), false, d)
  28735. }
  28736. func (f fastpathT) DecMapInt32Int16X(vp *map[int32]int16, d *Decoder) {
  28737. if v, changed := f.DecMapInt32Int16V(*vp, true, d); changed {
  28738. *vp = v
  28739. }
  28740. }
  28741. func (_ fastpathT) DecMapInt32Int16V(v map[int32]int16, canChange bool,
  28742. d *Decoder) (_ map[int32]int16, changed bool) {
  28743. dd, esep := d.d, d.hh.hasElemSeparators()
  28744. containerLen := dd.ReadMapStart()
  28745. if canChange && v == nil {
  28746. xlen := decInferLen(containerLen, d.h.MaxInitLen, 6)
  28747. v = make(map[int32]int16, xlen)
  28748. changed = true
  28749. }
  28750. if containerLen == 0 {
  28751. dd.ReadMapEnd()
  28752. return v, changed
  28753. }
  28754. var mk int32
  28755. var mv int16
  28756. hasLen := containerLen > 0
  28757. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28758. if esep {
  28759. dd.ReadMapElemKey()
  28760. }
  28761. mk = int32(dd.DecodeInt(32))
  28762. if esep {
  28763. dd.ReadMapElemValue()
  28764. }
  28765. if dd.TryDecodeAsNil() {
  28766. if d.h.DeleteOnNilMapValue {
  28767. delete(v, mk)
  28768. } else {
  28769. v[mk] = 0
  28770. }
  28771. continue
  28772. }
  28773. mv = int16(dd.DecodeInt(16))
  28774. if v != nil {
  28775. v[mk] = mv
  28776. }
  28777. }
  28778. dd.ReadMapEnd()
  28779. return v, changed
  28780. }
  28781. func (d *Decoder) fastpathDecMapInt32Int32R(f *codecFnInfo, rv reflect.Value) {
  28782. if rv.Kind() == reflect.Ptr {
  28783. vp := rv2i(rv).(*map[int32]int32)
  28784. if v, changed := fastpathTV.DecMapInt32Int32V(*vp, true, d); changed {
  28785. *vp = v
  28786. }
  28787. return
  28788. }
  28789. fastpathTV.DecMapInt32Int32V(rv2i(rv).(map[int32]int32), false, d)
  28790. }
  28791. func (f fastpathT) DecMapInt32Int32X(vp *map[int32]int32, d *Decoder) {
  28792. if v, changed := f.DecMapInt32Int32V(*vp, true, d); changed {
  28793. *vp = v
  28794. }
  28795. }
  28796. func (_ fastpathT) DecMapInt32Int32V(v map[int32]int32, canChange bool,
  28797. d *Decoder) (_ map[int32]int32, changed bool) {
  28798. dd, esep := d.d, d.hh.hasElemSeparators()
  28799. containerLen := dd.ReadMapStart()
  28800. if canChange && v == nil {
  28801. xlen := decInferLen(containerLen, d.h.MaxInitLen, 8)
  28802. v = make(map[int32]int32, xlen)
  28803. changed = true
  28804. }
  28805. if containerLen == 0 {
  28806. dd.ReadMapEnd()
  28807. return v, changed
  28808. }
  28809. var mk int32
  28810. var mv int32
  28811. hasLen := containerLen > 0
  28812. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28813. if esep {
  28814. dd.ReadMapElemKey()
  28815. }
  28816. mk = int32(dd.DecodeInt(32))
  28817. if esep {
  28818. dd.ReadMapElemValue()
  28819. }
  28820. if dd.TryDecodeAsNil() {
  28821. if d.h.DeleteOnNilMapValue {
  28822. delete(v, mk)
  28823. } else {
  28824. v[mk] = 0
  28825. }
  28826. continue
  28827. }
  28828. mv = int32(dd.DecodeInt(32))
  28829. if v != nil {
  28830. v[mk] = mv
  28831. }
  28832. }
  28833. dd.ReadMapEnd()
  28834. return v, changed
  28835. }
  28836. func (d *Decoder) fastpathDecMapInt32Int64R(f *codecFnInfo, rv reflect.Value) {
  28837. if rv.Kind() == reflect.Ptr {
  28838. vp := rv2i(rv).(*map[int32]int64)
  28839. if v, changed := fastpathTV.DecMapInt32Int64V(*vp, true, d); changed {
  28840. *vp = v
  28841. }
  28842. return
  28843. }
  28844. fastpathTV.DecMapInt32Int64V(rv2i(rv).(map[int32]int64), false, d)
  28845. }
  28846. func (f fastpathT) DecMapInt32Int64X(vp *map[int32]int64, d *Decoder) {
  28847. if v, changed := f.DecMapInt32Int64V(*vp, true, d); changed {
  28848. *vp = v
  28849. }
  28850. }
  28851. func (_ fastpathT) DecMapInt32Int64V(v map[int32]int64, canChange bool,
  28852. d *Decoder) (_ map[int32]int64, changed bool) {
  28853. dd, esep := d.d, d.hh.hasElemSeparators()
  28854. containerLen := dd.ReadMapStart()
  28855. if canChange && v == nil {
  28856. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  28857. v = make(map[int32]int64, xlen)
  28858. changed = true
  28859. }
  28860. if containerLen == 0 {
  28861. dd.ReadMapEnd()
  28862. return v, changed
  28863. }
  28864. var mk int32
  28865. var mv int64
  28866. hasLen := containerLen > 0
  28867. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28868. if esep {
  28869. dd.ReadMapElemKey()
  28870. }
  28871. mk = int32(dd.DecodeInt(32))
  28872. if esep {
  28873. dd.ReadMapElemValue()
  28874. }
  28875. if dd.TryDecodeAsNil() {
  28876. if d.h.DeleteOnNilMapValue {
  28877. delete(v, mk)
  28878. } else {
  28879. v[mk] = 0
  28880. }
  28881. continue
  28882. }
  28883. mv = dd.DecodeInt(64)
  28884. if v != nil {
  28885. v[mk] = mv
  28886. }
  28887. }
  28888. dd.ReadMapEnd()
  28889. return v, changed
  28890. }
  28891. func (d *Decoder) fastpathDecMapInt32Float32R(f *codecFnInfo, rv reflect.Value) {
  28892. if rv.Kind() == reflect.Ptr {
  28893. vp := rv2i(rv).(*map[int32]float32)
  28894. if v, changed := fastpathTV.DecMapInt32Float32V(*vp, true, d); changed {
  28895. *vp = v
  28896. }
  28897. return
  28898. }
  28899. fastpathTV.DecMapInt32Float32V(rv2i(rv).(map[int32]float32), false, d)
  28900. }
  28901. func (f fastpathT) DecMapInt32Float32X(vp *map[int32]float32, d *Decoder) {
  28902. if v, changed := f.DecMapInt32Float32V(*vp, true, d); changed {
  28903. *vp = v
  28904. }
  28905. }
  28906. func (_ fastpathT) DecMapInt32Float32V(v map[int32]float32, canChange bool,
  28907. d *Decoder) (_ map[int32]float32, changed bool) {
  28908. dd, esep := d.d, d.hh.hasElemSeparators()
  28909. containerLen := dd.ReadMapStart()
  28910. if canChange && v == nil {
  28911. xlen := decInferLen(containerLen, d.h.MaxInitLen, 8)
  28912. v = make(map[int32]float32, xlen)
  28913. changed = true
  28914. }
  28915. if containerLen == 0 {
  28916. dd.ReadMapEnd()
  28917. return v, changed
  28918. }
  28919. var mk int32
  28920. var mv float32
  28921. hasLen := containerLen > 0
  28922. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28923. if esep {
  28924. dd.ReadMapElemKey()
  28925. }
  28926. mk = int32(dd.DecodeInt(32))
  28927. if esep {
  28928. dd.ReadMapElemValue()
  28929. }
  28930. if dd.TryDecodeAsNil() {
  28931. if d.h.DeleteOnNilMapValue {
  28932. delete(v, mk)
  28933. } else {
  28934. v[mk] = 0
  28935. }
  28936. continue
  28937. }
  28938. mv = float32(dd.DecodeFloat(true))
  28939. if v != nil {
  28940. v[mk] = mv
  28941. }
  28942. }
  28943. dd.ReadMapEnd()
  28944. return v, changed
  28945. }
  28946. func (d *Decoder) fastpathDecMapInt32Float64R(f *codecFnInfo, rv reflect.Value) {
  28947. if rv.Kind() == reflect.Ptr {
  28948. vp := rv2i(rv).(*map[int32]float64)
  28949. if v, changed := fastpathTV.DecMapInt32Float64V(*vp, true, d); changed {
  28950. *vp = v
  28951. }
  28952. return
  28953. }
  28954. fastpathTV.DecMapInt32Float64V(rv2i(rv).(map[int32]float64), false, d)
  28955. }
  28956. func (f fastpathT) DecMapInt32Float64X(vp *map[int32]float64, d *Decoder) {
  28957. if v, changed := f.DecMapInt32Float64V(*vp, true, d); changed {
  28958. *vp = v
  28959. }
  28960. }
  28961. func (_ fastpathT) DecMapInt32Float64V(v map[int32]float64, canChange bool,
  28962. d *Decoder) (_ map[int32]float64, changed bool) {
  28963. dd, esep := d.d, d.hh.hasElemSeparators()
  28964. containerLen := dd.ReadMapStart()
  28965. if canChange && v == nil {
  28966. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  28967. v = make(map[int32]float64, xlen)
  28968. changed = true
  28969. }
  28970. if containerLen == 0 {
  28971. dd.ReadMapEnd()
  28972. return v, changed
  28973. }
  28974. var mk int32
  28975. var mv float64
  28976. hasLen := containerLen > 0
  28977. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28978. if esep {
  28979. dd.ReadMapElemKey()
  28980. }
  28981. mk = int32(dd.DecodeInt(32))
  28982. if esep {
  28983. dd.ReadMapElemValue()
  28984. }
  28985. if dd.TryDecodeAsNil() {
  28986. if d.h.DeleteOnNilMapValue {
  28987. delete(v, mk)
  28988. } else {
  28989. v[mk] = 0
  28990. }
  28991. continue
  28992. }
  28993. mv = dd.DecodeFloat(false)
  28994. if v != nil {
  28995. v[mk] = mv
  28996. }
  28997. }
  28998. dd.ReadMapEnd()
  28999. return v, changed
  29000. }
  29001. func (d *Decoder) fastpathDecMapInt32BoolR(f *codecFnInfo, rv reflect.Value) {
  29002. if rv.Kind() == reflect.Ptr {
  29003. vp := rv2i(rv).(*map[int32]bool)
  29004. if v, changed := fastpathTV.DecMapInt32BoolV(*vp, true, d); changed {
  29005. *vp = v
  29006. }
  29007. return
  29008. }
  29009. fastpathTV.DecMapInt32BoolV(rv2i(rv).(map[int32]bool), false, d)
  29010. }
  29011. func (f fastpathT) DecMapInt32BoolX(vp *map[int32]bool, d *Decoder) {
  29012. if v, changed := f.DecMapInt32BoolV(*vp, true, d); changed {
  29013. *vp = v
  29014. }
  29015. }
  29016. func (_ fastpathT) DecMapInt32BoolV(v map[int32]bool, canChange bool,
  29017. d *Decoder) (_ map[int32]bool, changed bool) {
  29018. dd, esep := d.d, d.hh.hasElemSeparators()
  29019. containerLen := dd.ReadMapStart()
  29020. if canChange && v == nil {
  29021. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  29022. v = make(map[int32]bool, xlen)
  29023. changed = true
  29024. }
  29025. if containerLen == 0 {
  29026. dd.ReadMapEnd()
  29027. return v, changed
  29028. }
  29029. var mk int32
  29030. var mv bool
  29031. hasLen := containerLen > 0
  29032. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29033. if esep {
  29034. dd.ReadMapElemKey()
  29035. }
  29036. mk = int32(dd.DecodeInt(32))
  29037. if esep {
  29038. dd.ReadMapElemValue()
  29039. }
  29040. if dd.TryDecodeAsNil() {
  29041. if d.h.DeleteOnNilMapValue {
  29042. delete(v, mk)
  29043. } else {
  29044. v[mk] = false
  29045. }
  29046. continue
  29047. }
  29048. mv = dd.DecodeBool()
  29049. if v != nil {
  29050. v[mk] = mv
  29051. }
  29052. }
  29053. dd.ReadMapEnd()
  29054. return v, changed
  29055. }
  29056. func (d *Decoder) fastpathDecMapInt64IntfR(f *codecFnInfo, rv reflect.Value) {
  29057. if rv.Kind() == reflect.Ptr {
  29058. vp := rv2i(rv).(*map[int64]interface{})
  29059. if v, changed := fastpathTV.DecMapInt64IntfV(*vp, true, d); changed {
  29060. *vp = v
  29061. }
  29062. return
  29063. }
  29064. fastpathTV.DecMapInt64IntfV(rv2i(rv).(map[int64]interface{}), false, d)
  29065. }
  29066. func (f fastpathT) DecMapInt64IntfX(vp *map[int64]interface{}, d *Decoder) {
  29067. if v, changed := f.DecMapInt64IntfV(*vp, true, d); changed {
  29068. *vp = v
  29069. }
  29070. }
  29071. func (_ fastpathT) DecMapInt64IntfV(v map[int64]interface{}, canChange bool,
  29072. d *Decoder) (_ map[int64]interface{}, changed bool) {
  29073. dd, esep := d.d, d.hh.hasElemSeparators()
  29074. containerLen := dd.ReadMapStart()
  29075. if canChange && v == nil {
  29076. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  29077. v = make(map[int64]interface{}, xlen)
  29078. changed = true
  29079. }
  29080. if containerLen == 0 {
  29081. dd.ReadMapEnd()
  29082. return v, changed
  29083. }
  29084. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  29085. var mk int64
  29086. var mv interface{}
  29087. hasLen := containerLen > 0
  29088. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29089. if esep {
  29090. dd.ReadMapElemKey()
  29091. }
  29092. mk = dd.DecodeInt(64)
  29093. if esep {
  29094. dd.ReadMapElemValue()
  29095. }
  29096. if dd.TryDecodeAsNil() {
  29097. if d.h.DeleteOnNilMapValue {
  29098. delete(v, mk)
  29099. } else {
  29100. v[mk] = nil
  29101. }
  29102. continue
  29103. }
  29104. if mapGet {
  29105. mv = v[mk]
  29106. } else {
  29107. mv = nil
  29108. }
  29109. d.decode(&mv)
  29110. if v != nil {
  29111. v[mk] = mv
  29112. }
  29113. }
  29114. dd.ReadMapEnd()
  29115. return v, changed
  29116. }
  29117. func (d *Decoder) fastpathDecMapInt64StringR(f *codecFnInfo, rv reflect.Value) {
  29118. if rv.Kind() == reflect.Ptr {
  29119. vp := rv2i(rv).(*map[int64]string)
  29120. if v, changed := fastpathTV.DecMapInt64StringV(*vp, true, d); changed {
  29121. *vp = v
  29122. }
  29123. return
  29124. }
  29125. fastpathTV.DecMapInt64StringV(rv2i(rv).(map[int64]string), false, d)
  29126. }
  29127. func (f fastpathT) DecMapInt64StringX(vp *map[int64]string, d *Decoder) {
  29128. if v, changed := f.DecMapInt64StringV(*vp, true, d); changed {
  29129. *vp = v
  29130. }
  29131. }
  29132. func (_ fastpathT) DecMapInt64StringV(v map[int64]string, canChange bool,
  29133. d *Decoder) (_ map[int64]string, changed bool) {
  29134. dd, esep := d.d, d.hh.hasElemSeparators()
  29135. containerLen := dd.ReadMapStart()
  29136. if canChange && v == nil {
  29137. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  29138. v = make(map[int64]string, xlen)
  29139. changed = true
  29140. }
  29141. if containerLen == 0 {
  29142. dd.ReadMapEnd()
  29143. return v, changed
  29144. }
  29145. var mk int64
  29146. var mv string
  29147. hasLen := containerLen > 0
  29148. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29149. if esep {
  29150. dd.ReadMapElemKey()
  29151. }
  29152. mk = dd.DecodeInt(64)
  29153. if esep {
  29154. dd.ReadMapElemValue()
  29155. }
  29156. if dd.TryDecodeAsNil() {
  29157. if d.h.DeleteOnNilMapValue {
  29158. delete(v, mk)
  29159. } else {
  29160. v[mk] = ""
  29161. }
  29162. continue
  29163. }
  29164. mv = dd.DecodeString()
  29165. if v != nil {
  29166. v[mk] = mv
  29167. }
  29168. }
  29169. dd.ReadMapEnd()
  29170. return v, changed
  29171. }
  29172. func (d *Decoder) fastpathDecMapInt64UintR(f *codecFnInfo, rv reflect.Value) {
  29173. if rv.Kind() == reflect.Ptr {
  29174. vp := rv2i(rv).(*map[int64]uint)
  29175. if v, changed := fastpathTV.DecMapInt64UintV(*vp, true, d); changed {
  29176. *vp = v
  29177. }
  29178. return
  29179. }
  29180. fastpathTV.DecMapInt64UintV(rv2i(rv).(map[int64]uint), false, d)
  29181. }
  29182. func (f fastpathT) DecMapInt64UintX(vp *map[int64]uint, d *Decoder) {
  29183. if v, changed := f.DecMapInt64UintV(*vp, true, d); changed {
  29184. *vp = v
  29185. }
  29186. }
  29187. func (_ fastpathT) DecMapInt64UintV(v map[int64]uint, canChange bool,
  29188. d *Decoder) (_ map[int64]uint, changed bool) {
  29189. dd, esep := d.d, d.hh.hasElemSeparators()
  29190. containerLen := dd.ReadMapStart()
  29191. if canChange && v == nil {
  29192. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  29193. v = make(map[int64]uint, xlen)
  29194. changed = true
  29195. }
  29196. if containerLen == 0 {
  29197. dd.ReadMapEnd()
  29198. return v, changed
  29199. }
  29200. var mk int64
  29201. var mv uint
  29202. hasLen := containerLen > 0
  29203. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29204. if esep {
  29205. dd.ReadMapElemKey()
  29206. }
  29207. mk = dd.DecodeInt(64)
  29208. if esep {
  29209. dd.ReadMapElemValue()
  29210. }
  29211. if dd.TryDecodeAsNil() {
  29212. if d.h.DeleteOnNilMapValue {
  29213. delete(v, mk)
  29214. } else {
  29215. v[mk] = 0
  29216. }
  29217. continue
  29218. }
  29219. mv = uint(dd.DecodeUint(uintBitsize))
  29220. if v != nil {
  29221. v[mk] = mv
  29222. }
  29223. }
  29224. dd.ReadMapEnd()
  29225. return v, changed
  29226. }
  29227. func (d *Decoder) fastpathDecMapInt64Uint8R(f *codecFnInfo, rv reflect.Value) {
  29228. if rv.Kind() == reflect.Ptr {
  29229. vp := rv2i(rv).(*map[int64]uint8)
  29230. if v, changed := fastpathTV.DecMapInt64Uint8V(*vp, true, d); changed {
  29231. *vp = v
  29232. }
  29233. return
  29234. }
  29235. fastpathTV.DecMapInt64Uint8V(rv2i(rv).(map[int64]uint8), false, d)
  29236. }
  29237. func (f fastpathT) DecMapInt64Uint8X(vp *map[int64]uint8, d *Decoder) {
  29238. if v, changed := f.DecMapInt64Uint8V(*vp, true, d); changed {
  29239. *vp = v
  29240. }
  29241. }
  29242. func (_ fastpathT) DecMapInt64Uint8V(v map[int64]uint8, canChange bool,
  29243. d *Decoder) (_ map[int64]uint8, changed bool) {
  29244. dd, esep := d.d, d.hh.hasElemSeparators()
  29245. containerLen := dd.ReadMapStart()
  29246. if canChange && v == nil {
  29247. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  29248. v = make(map[int64]uint8, xlen)
  29249. changed = true
  29250. }
  29251. if containerLen == 0 {
  29252. dd.ReadMapEnd()
  29253. return v, changed
  29254. }
  29255. var mk int64
  29256. var mv uint8
  29257. hasLen := containerLen > 0
  29258. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29259. if esep {
  29260. dd.ReadMapElemKey()
  29261. }
  29262. mk = dd.DecodeInt(64)
  29263. if esep {
  29264. dd.ReadMapElemValue()
  29265. }
  29266. if dd.TryDecodeAsNil() {
  29267. if d.h.DeleteOnNilMapValue {
  29268. delete(v, mk)
  29269. } else {
  29270. v[mk] = 0
  29271. }
  29272. continue
  29273. }
  29274. mv = uint8(dd.DecodeUint(8))
  29275. if v != nil {
  29276. v[mk] = mv
  29277. }
  29278. }
  29279. dd.ReadMapEnd()
  29280. return v, changed
  29281. }
  29282. func (d *Decoder) fastpathDecMapInt64Uint16R(f *codecFnInfo, rv reflect.Value) {
  29283. if rv.Kind() == reflect.Ptr {
  29284. vp := rv2i(rv).(*map[int64]uint16)
  29285. if v, changed := fastpathTV.DecMapInt64Uint16V(*vp, true, d); changed {
  29286. *vp = v
  29287. }
  29288. return
  29289. }
  29290. fastpathTV.DecMapInt64Uint16V(rv2i(rv).(map[int64]uint16), false, d)
  29291. }
  29292. func (f fastpathT) DecMapInt64Uint16X(vp *map[int64]uint16, d *Decoder) {
  29293. if v, changed := f.DecMapInt64Uint16V(*vp, true, d); changed {
  29294. *vp = v
  29295. }
  29296. }
  29297. func (_ fastpathT) DecMapInt64Uint16V(v map[int64]uint16, canChange bool,
  29298. d *Decoder) (_ map[int64]uint16, changed bool) {
  29299. dd, esep := d.d, d.hh.hasElemSeparators()
  29300. containerLen := dd.ReadMapStart()
  29301. if canChange && v == nil {
  29302. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  29303. v = make(map[int64]uint16, xlen)
  29304. changed = true
  29305. }
  29306. if containerLen == 0 {
  29307. dd.ReadMapEnd()
  29308. return v, changed
  29309. }
  29310. var mk int64
  29311. var mv uint16
  29312. hasLen := containerLen > 0
  29313. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29314. if esep {
  29315. dd.ReadMapElemKey()
  29316. }
  29317. mk = dd.DecodeInt(64)
  29318. if esep {
  29319. dd.ReadMapElemValue()
  29320. }
  29321. if dd.TryDecodeAsNil() {
  29322. if d.h.DeleteOnNilMapValue {
  29323. delete(v, mk)
  29324. } else {
  29325. v[mk] = 0
  29326. }
  29327. continue
  29328. }
  29329. mv = uint16(dd.DecodeUint(16))
  29330. if v != nil {
  29331. v[mk] = mv
  29332. }
  29333. }
  29334. dd.ReadMapEnd()
  29335. return v, changed
  29336. }
  29337. func (d *Decoder) fastpathDecMapInt64Uint32R(f *codecFnInfo, rv reflect.Value) {
  29338. if rv.Kind() == reflect.Ptr {
  29339. vp := rv2i(rv).(*map[int64]uint32)
  29340. if v, changed := fastpathTV.DecMapInt64Uint32V(*vp, true, d); changed {
  29341. *vp = v
  29342. }
  29343. return
  29344. }
  29345. fastpathTV.DecMapInt64Uint32V(rv2i(rv).(map[int64]uint32), false, d)
  29346. }
  29347. func (f fastpathT) DecMapInt64Uint32X(vp *map[int64]uint32, d *Decoder) {
  29348. if v, changed := f.DecMapInt64Uint32V(*vp, true, d); changed {
  29349. *vp = v
  29350. }
  29351. }
  29352. func (_ fastpathT) DecMapInt64Uint32V(v map[int64]uint32, canChange bool,
  29353. d *Decoder) (_ map[int64]uint32, changed bool) {
  29354. dd, esep := d.d, d.hh.hasElemSeparators()
  29355. containerLen := dd.ReadMapStart()
  29356. if canChange && v == nil {
  29357. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  29358. v = make(map[int64]uint32, xlen)
  29359. changed = true
  29360. }
  29361. if containerLen == 0 {
  29362. dd.ReadMapEnd()
  29363. return v, changed
  29364. }
  29365. var mk int64
  29366. var mv uint32
  29367. hasLen := containerLen > 0
  29368. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29369. if esep {
  29370. dd.ReadMapElemKey()
  29371. }
  29372. mk = dd.DecodeInt(64)
  29373. if esep {
  29374. dd.ReadMapElemValue()
  29375. }
  29376. if dd.TryDecodeAsNil() {
  29377. if d.h.DeleteOnNilMapValue {
  29378. delete(v, mk)
  29379. } else {
  29380. v[mk] = 0
  29381. }
  29382. continue
  29383. }
  29384. mv = uint32(dd.DecodeUint(32))
  29385. if v != nil {
  29386. v[mk] = mv
  29387. }
  29388. }
  29389. dd.ReadMapEnd()
  29390. return v, changed
  29391. }
  29392. func (d *Decoder) fastpathDecMapInt64Uint64R(f *codecFnInfo, rv reflect.Value) {
  29393. if rv.Kind() == reflect.Ptr {
  29394. vp := rv2i(rv).(*map[int64]uint64)
  29395. if v, changed := fastpathTV.DecMapInt64Uint64V(*vp, true, d); changed {
  29396. *vp = v
  29397. }
  29398. return
  29399. }
  29400. fastpathTV.DecMapInt64Uint64V(rv2i(rv).(map[int64]uint64), false, d)
  29401. }
  29402. func (f fastpathT) DecMapInt64Uint64X(vp *map[int64]uint64, d *Decoder) {
  29403. if v, changed := f.DecMapInt64Uint64V(*vp, true, d); changed {
  29404. *vp = v
  29405. }
  29406. }
  29407. func (_ fastpathT) DecMapInt64Uint64V(v map[int64]uint64, canChange bool,
  29408. d *Decoder) (_ map[int64]uint64, changed bool) {
  29409. dd, esep := d.d, d.hh.hasElemSeparators()
  29410. containerLen := dd.ReadMapStart()
  29411. if canChange && v == nil {
  29412. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  29413. v = make(map[int64]uint64, xlen)
  29414. changed = true
  29415. }
  29416. if containerLen == 0 {
  29417. dd.ReadMapEnd()
  29418. return v, changed
  29419. }
  29420. var mk int64
  29421. var mv uint64
  29422. hasLen := containerLen > 0
  29423. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29424. if esep {
  29425. dd.ReadMapElemKey()
  29426. }
  29427. mk = dd.DecodeInt(64)
  29428. if esep {
  29429. dd.ReadMapElemValue()
  29430. }
  29431. if dd.TryDecodeAsNil() {
  29432. if d.h.DeleteOnNilMapValue {
  29433. delete(v, mk)
  29434. } else {
  29435. v[mk] = 0
  29436. }
  29437. continue
  29438. }
  29439. mv = dd.DecodeUint(64)
  29440. if v != nil {
  29441. v[mk] = mv
  29442. }
  29443. }
  29444. dd.ReadMapEnd()
  29445. return v, changed
  29446. }
  29447. func (d *Decoder) fastpathDecMapInt64UintptrR(f *codecFnInfo, rv reflect.Value) {
  29448. if rv.Kind() == reflect.Ptr {
  29449. vp := rv2i(rv).(*map[int64]uintptr)
  29450. if v, changed := fastpathTV.DecMapInt64UintptrV(*vp, true, d); changed {
  29451. *vp = v
  29452. }
  29453. return
  29454. }
  29455. fastpathTV.DecMapInt64UintptrV(rv2i(rv).(map[int64]uintptr), false, d)
  29456. }
  29457. func (f fastpathT) DecMapInt64UintptrX(vp *map[int64]uintptr, d *Decoder) {
  29458. if v, changed := f.DecMapInt64UintptrV(*vp, true, d); changed {
  29459. *vp = v
  29460. }
  29461. }
  29462. func (_ fastpathT) DecMapInt64UintptrV(v map[int64]uintptr, canChange bool,
  29463. d *Decoder) (_ map[int64]uintptr, changed bool) {
  29464. dd, esep := d.d, d.hh.hasElemSeparators()
  29465. containerLen := dd.ReadMapStart()
  29466. if canChange && v == nil {
  29467. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  29468. v = make(map[int64]uintptr, xlen)
  29469. changed = true
  29470. }
  29471. if containerLen == 0 {
  29472. dd.ReadMapEnd()
  29473. return v, changed
  29474. }
  29475. var mk int64
  29476. var mv uintptr
  29477. hasLen := containerLen > 0
  29478. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29479. if esep {
  29480. dd.ReadMapElemKey()
  29481. }
  29482. mk = dd.DecodeInt(64)
  29483. if esep {
  29484. dd.ReadMapElemValue()
  29485. }
  29486. if dd.TryDecodeAsNil() {
  29487. if d.h.DeleteOnNilMapValue {
  29488. delete(v, mk)
  29489. } else {
  29490. v[mk] = 0
  29491. }
  29492. continue
  29493. }
  29494. mv = uintptr(dd.DecodeUint(uintBitsize))
  29495. if v != nil {
  29496. v[mk] = mv
  29497. }
  29498. }
  29499. dd.ReadMapEnd()
  29500. return v, changed
  29501. }
  29502. func (d *Decoder) fastpathDecMapInt64IntR(f *codecFnInfo, rv reflect.Value) {
  29503. if rv.Kind() == reflect.Ptr {
  29504. vp := rv2i(rv).(*map[int64]int)
  29505. if v, changed := fastpathTV.DecMapInt64IntV(*vp, true, d); changed {
  29506. *vp = v
  29507. }
  29508. return
  29509. }
  29510. fastpathTV.DecMapInt64IntV(rv2i(rv).(map[int64]int), false, d)
  29511. }
  29512. func (f fastpathT) DecMapInt64IntX(vp *map[int64]int, d *Decoder) {
  29513. if v, changed := f.DecMapInt64IntV(*vp, true, d); changed {
  29514. *vp = v
  29515. }
  29516. }
  29517. func (_ fastpathT) DecMapInt64IntV(v map[int64]int, canChange bool,
  29518. d *Decoder) (_ map[int64]int, changed bool) {
  29519. dd, esep := d.d, d.hh.hasElemSeparators()
  29520. containerLen := dd.ReadMapStart()
  29521. if canChange && v == nil {
  29522. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  29523. v = make(map[int64]int, xlen)
  29524. changed = true
  29525. }
  29526. if containerLen == 0 {
  29527. dd.ReadMapEnd()
  29528. return v, changed
  29529. }
  29530. var mk int64
  29531. var mv int
  29532. hasLen := containerLen > 0
  29533. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29534. if esep {
  29535. dd.ReadMapElemKey()
  29536. }
  29537. mk = dd.DecodeInt(64)
  29538. if esep {
  29539. dd.ReadMapElemValue()
  29540. }
  29541. if dd.TryDecodeAsNil() {
  29542. if d.h.DeleteOnNilMapValue {
  29543. delete(v, mk)
  29544. } else {
  29545. v[mk] = 0
  29546. }
  29547. continue
  29548. }
  29549. mv = int(dd.DecodeInt(intBitsize))
  29550. if v != nil {
  29551. v[mk] = mv
  29552. }
  29553. }
  29554. dd.ReadMapEnd()
  29555. return v, changed
  29556. }
  29557. func (d *Decoder) fastpathDecMapInt64Int8R(f *codecFnInfo, rv reflect.Value) {
  29558. if rv.Kind() == reflect.Ptr {
  29559. vp := rv2i(rv).(*map[int64]int8)
  29560. if v, changed := fastpathTV.DecMapInt64Int8V(*vp, true, d); changed {
  29561. *vp = v
  29562. }
  29563. return
  29564. }
  29565. fastpathTV.DecMapInt64Int8V(rv2i(rv).(map[int64]int8), false, d)
  29566. }
  29567. func (f fastpathT) DecMapInt64Int8X(vp *map[int64]int8, d *Decoder) {
  29568. if v, changed := f.DecMapInt64Int8V(*vp, true, d); changed {
  29569. *vp = v
  29570. }
  29571. }
  29572. func (_ fastpathT) DecMapInt64Int8V(v map[int64]int8, canChange bool,
  29573. d *Decoder) (_ map[int64]int8, changed bool) {
  29574. dd, esep := d.d, d.hh.hasElemSeparators()
  29575. containerLen := dd.ReadMapStart()
  29576. if canChange && v == nil {
  29577. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  29578. v = make(map[int64]int8, xlen)
  29579. changed = true
  29580. }
  29581. if containerLen == 0 {
  29582. dd.ReadMapEnd()
  29583. return v, changed
  29584. }
  29585. var mk int64
  29586. var mv int8
  29587. hasLen := containerLen > 0
  29588. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29589. if esep {
  29590. dd.ReadMapElemKey()
  29591. }
  29592. mk = dd.DecodeInt(64)
  29593. if esep {
  29594. dd.ReadMapElemValue()
  29595. }
  29596. if dd.TryDecodeAsNil() {
  29597. if d.h.DeleteOnNilMapValue {
  29598. delete(v, mk)
  29599. } else {
  29600. v[mk] = 0
  29601. }
  29602. continue
  29603. }
  29604. mv = int8(dd.DecodeInt(8))
  29605. if v != nil {
  29606. v[mk] = mv
  29607. }
  29608. }
  29609. dd.ReadMapEnd()
  29610. return v, changed
  29611. }
  29612. func (d *Decoder) fastpathDecMapInt64Int16R(f *codecFnInfo, rv reflect.Value) {
  29613. if rv.Kind() == reflect.Ptr {
  29614. vp := rv2i(rv).(*map[int64]int16)
  29615. if v, changed := fastpathTV.DecMapInt64Int16V(*vp, true, d); changed {
  29616. *vp = v
  29617. }
  29618. return
  29619. }
  29620. fastpathTV.DecMapInt64Int16V(rv2i(rv).(map[int64]int16), false, d)
  29621. }
  29622. func (f fastpathT) DecMapInt64Int16X(vp *map[int64]int16, d *Decoder) {
  29623. if v, changed := f.DecMapInt64Int16V(*vp, true, d); changed {
  29624. *vp = v
  29625. }
  29626. }
  29627. func (_ fastpathT) DecMapInt64Int16V(v map[int64]int16, canChange bool,
  29628. d *Decoder) (_ map[int64]int16, changed bool) {
  29629. dd, esep := d.d, d.hh.hasElemSeparators()
  29630. containerLen := dd.ReadMapStart()
  29631. if canChange && v == nil {
  29632. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  29633. v = make(map[int64]int16, xlen)
  29634. changed = true
  29635. }
  29636. if containerLen == 0 {
  29637. dd.ReadMapEnd()
  29638. return v, changed
  29639. }
  29640. var mk int64
  29641. var mv int16
  29642. hasLen := containerLen > 0
  29643. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29644. if esep {
  29645. dd.ReadMapElemKey()
  29646. }
  29647. mk = dd.DecodeInt(64)
  29648. if esep {
  29649. dd.ReadMapElemValue()
  29650. }
  29651. if dd.TryDecodeAsNil() {
  29652. if d.h.DeleteOnNilMapValue {
  29653. delete(v, mk)
  29654. } else {
  29655. v[mk] = 0
  29656. }
  29657. continue
  29658. }
  29659. mv = int16(dd.DecodeInt(16))
  29660. if v != nil {
  29661. v[mk] = mv
  29662. }
  29663. }
  29664. dd.ReadMapEnd()
  29665. return v, changed
  29666. }
  29667. func (d *Decoder) fastpathDecMapInt64Int32R(f *codecFnInfo, rv reflect.Value) {
  29668. if rv.Kind() == reflect.Ptr {
  29669. vp := rv2i(rv).(*map[int64]int32)
  29670. if v, changed := fastpathTV.DecMapInt64Int32V(*vp, true, d); changed {
  29671. *vp = v
  29672. }
  29673. return
  29674. }
  29675. fastpathTV.DecMapInt64Int32V(rv2i(rv).(map[int64]int32), false, d)
  29676. }
  29677. func (f fastpathT) DecMapInt64Int32X(vp *map[int64]int32, d *Decoder) {
  29678. if v, changed := f.DecMapInt64Int32V(*vp, true, d); changed {
  29679. *vp = v
  29680. }
  29681. }
  29682. func (_ fastpathT) DecMapInt64Int32V(v map[int64]int32, canChange bool,
  29683. d *Decoder) (_ map[int64]int32, changed bool) {
  29684. dd, esep := d.d, d.hh.hasElemSeparators()
  29685. containerLen := dd.ReadMapStart()
  29686. if canChange && v == nil {
  29687. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  29688. v = make(map[int64]int32, xlen)
  29689. changed = true
  29690. }
  29691. if containerLen == 0 {
  29692. dd.ReadMapEnd()
  29693. return v, changed
  29694. }
  29695. var mk int64
  29696. var mv int32
  29697. hasLen := containerLen > 0
  29698. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29699. if esep {
  29700. dd.ReadMapElemKey()
  29701. }
  29702. mk = dd.DecodeInt(64)
  29703. if esep {
  29704. dd.ReadMapElemValue()
  29705. }
  29706. if dd.TryDecodeAsNil() {
  29707. if d.h.DeleteOnNilMapValue {
  29708. delete(v, mk)
  29709. } else {
  29710. v[mk] = 0
  29711. }
  29712. continue
  29713. }
  29714. mv = int32(dd.DecodeInt(32))
  29715. if v != nil {
  29716. v[mk] = mv
  29717. }
  29718. }
  29719. dd.ReadMapEnd()
  29720. return v, changed
  29721. }
  29722. func (d *Decoder) fastpathDecMapInt64Int64R(f *codecFnInfo, rv reflect.Value) {
  29723. if rv.Kind() == reflect.Ptr {
  29724. vp := rv2i(rv).(*map[int64]int64)
  29725. if v, changed := fastpathTV.DecMapInt64Int64V(*vp, true, d); changed {
  29726. *vp = v
  29727. }
  29728. return
  29729. }
  29730. fastpathTV.DecMapInt64Int64V(rv2i(rv).(map[int64]int64), false, d)
  29731. }
  29732. func (f fastpathT) DecMapInt64Int64X(vp *map[int64]int64, d *Decoder) {
  29733. if v, changed := f.DecMapInt64Int64V(*vp, true, d); changed {
  29734. *vp = v
  29735. }
  29736. }
  29737. func (_ fastpathT) DecMapInt64Int64V(v map[int64]int64, canChange bool,
  29738. d *Decoder) (_ map[int64]int64, changed bool) {
  29739. dd, esep := d.d, d.hh.hasElemSeparators()
  29740. containerLen := dd.ReadMapStart()
  29741. if canChange && v == nil {
  29742. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  29743. v = make(map[int64]int64, xlen)
  29744. changed = true
  29745. }
  29746. if containerLen == 0 {
  29747. dd.ReadMapEnd()
  29748. return v, changed
  29749. }
  29750. var mk int64
  29751. var mv int64
  29752. hasLen := containerLen > 0
  29753. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29754. if esep {
  29755. dd.ReadMapElemKey()
  29756. }
  29757. mk = dd.DecodeInt(64)
  29758. if esep {
  29759. dd.ReadMapElemValue()
  29760. }
  29761. if dd.TryDecodeAsNil() {
  29762. if d.h.DeleteOnNilMapValue {
  29763. delete(v, mk)
  29764. } else {
  29765. v[mk] = 0
  29766. }
  29767. continue
  29768. }
  29769. mv = dd.DecodeInt(64)
  29770. if v != nil {
  29771. v[mk] = mv
  29772. }
  29773. }
  29774. dd.ReadMapEnd()
  29775. return v, changed
  29776. }
  29777. func (d *Decoder) fastpathDecMapInt64Float32R(f *codecFnInfo, rv reflect.Value) {
  29778. if rv.Kind() == reflect.Ptr {
  29779. vp := rv2i(rv).(*map[int64]float32)
  29780. if v, changed := fastpathTV.DecMapInt64Float32V(*vp, true, d); changed {
  29781. *vp = v
  29782. }
  29783. return
  29784. }
  29785. fastpathTV.DecMapInt64Float32V(rv2i(rv).(map[int64]float32), false, d)
  29786. }
  29787. func (f fastpathT) DecMapInt64Float32X(vp *map[int64]float32, d *Decoder) {
  29788. if v, changed := f.DecMapInt64Float32V(*vp, true, d); changed {
  29789. *vp = v
  29790. }
  29791. }
  29792. func (_ fastpathT) DecMapInt64Float32V(v map[int64]float32, canChange bool,
  29793. d *Decoder) (_ map[int64]float32, changed bool) {
  29794. dd, esep := d.d, d.hh.hasElemSeparators()
  29795. containerLen := dd.ReadMapStart()
  29796. if canChange && v == nil {
  29797. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  29798. v = make(map[int64]float32, xlen)
  29799. changed = true
  29800. }
  29801. if containerLen == 0 {
  29802. dd.ReadMapEnd()
  29803. return v, changed
  29804. }
  29805. var mk int64
  29806. var mv float32
  29807. hasLen := containerLen > 0
  29808. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29809. if esep {
  29810. dd.ReadMapElemKey()
  29811. }
  29812. mk = dd.DecodeInt(64)
  29813. if esep {
  29814. dd.ReadMapElemValue()
  29815. }
  29816. if dd.TryDecodeAsNil() {
  29817. if d.h.DeleteOnNilMapValue {
  29818. delete(v, mk)
  29819. } else {
  29820. v[mk] = 0
  29821. }
  29822. continue
  29823. }
  29824. mv = float32(dd.DecodeFloat(true))
  29825. if v != nil {
  29826. v[mk] = mv
  29827. }
  29828. }
  29829. dd.ReadMapEnd()
  29830. return v, changed
  29831. }
  29832. func (d *Decoder) fastpathDecMapInt64Float64R(f *codecFnInfo, rv reflect.Value) {
  29833. if rv.Kind() == reflect.Ptr {
  29834. vp := rv2i(rv).(*map[int64]float64)
  29835. if v, changed := fastpathTV.DecMapInt64Float64V(*vp, true, d); changed {
  29836. *vp = v
  29837. }
  29838. return
  29839. }
  29840. fastpathTV.DecMapInt64Float64V(rv2i(rv).(map[int64]float64), false, d)
  29841. }
  29842. func (f fastpathT) DecMapInt64Float64X(vp *map[int64]float64, d *Decoder) {
  29843. if v, changed := f.DecMapInt64Float64V(*vp, true, d); changed {
  29844. *vp = v
  29845. }
  29846. }
  29847. func (_ fastpathT) DecMapInt64Float64V(v map[int64]float64, canChange bool,
  29848. d *Decoder) (_ map[int64]float64, changed bool) {
  29849. dd, esep := d.d, d.hh.hasElemSeparators()
  29850. containerLen := dd.ReadMapStart()
  29851. if canChange && v == nil {
  29852. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  29853. v = make(map[int64]float64, xlen)
  29854. changed = true
  29855. }
  29856. if containerLen == 0 {
  29857. dd.ReadMapEnd()
  29858. return v, changed
  29859. }
  29860. var mk int64
  29861. var mv float64
  29862. hasLen := containerLen > 0
  29863. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29864. if esep {
  29865. dd.ReadMapElemKey()
  29866. }
  29867. mk = dd.DecodeInt(64)
  29868. if esep {
  29869. dd.ReadMapElemValue()
  29870. }
  29871. if dd.TryDecodeAsNil() {
  29872. if d.h.DeleteOnNilMapValue {
  29873. delete(v, mk)
  29874. } else {
  29875. v[mk] = 0
  29876. }
  29877. continue
  29878. }
  29879. mv = dd.DecodeFloat(false)
  29880. if v != nil {
  29881. v[mk] = mv
  29882. }
  29883. }
  29884. dd.ReadMapEnd()
  29885. return v, changed
  29886. }
  29887. func (d *Decoder) fastpathDecMapInt64BoolR(f *codecFnInfo, rv reflect.Value) {
  29888. if rv.Kind() == reflect.Ptr {
  29889. vp := rv2i(rv).(*map[int64]bool)
  29890. if v, changed := fastpathTV.DecMapInt64BoolV(*vp, true, d); changed {
  29891. *vp = v
  29892. }
  29893. return
  29894. }
  29895. fastpathTV.DecMapInt64BoolV(rv2i(rv).(map[int64]bool), false, d)
  29896. }
  29897. func (f fastpathT) DecMapInt64BoolX(vp *map[int64]bool, d *Decoder) {
  29898. if v, changed := f.DecMapInt64BoolV(*vp, true, d); changed {
  29899. *vp = v
  29900. }
  29901. }
  29902. func (_ fastpathT) DecMapInt64BoolV(v map[int64]bool, canChange bool,
  29903. d *Decoder) (_ map[int64]bool, changed bool) {
  29904. dd, esep := d.d, d.hh.hasElemSeparators()
  29905. containerLen := dd.ReadMapStart()
  29906. if canChange && v == nil {
  29907. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  29908. v = make(map[int64]bool, xlen)
  29909. changed = true
  29910. }
  29911. if containerLen == 0 {
  29912. dd.ReadMapEnd()
  29913. return v, changed
  29914. }
  29915. var mk int64
  29916. var mv bool
  29917. hasLen := containerLen > 0
  29918. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29919. if esep {
  29920. dd.ReadMapElemKey()
  29921. }
  29922. mk = dd.DecodeInt(64)
  29923. if esep {
  29924. dd.ReadMapElemValue()
  29925. }
  29926. if dd.TryDecodeAsNil() {
  29927. if d.h.DeleteOnNilMapValue {
  29928. delete(v, mk)
  29929. } else {
  29930. v[mk] = false
  29931. }
  29932. continue
  29933. }
  29934. mv = dd.DecodeBool()
  29935. if v != nil {
  29936. v[mk] = mv
  29937. }
  29938. }
  29939. dd.ReadMapEnd()
  29940. return v, changed
  29941. }
  29942. func (d *Decoder) fastpathDecMapBoolIntfR(f *codecFnInfo, rv reflect.Value) {
  29943. if rv.Kind() == reflect.Ptr {
  29944. vp := rv2i(rv).(*map[bool]interface{})
  29945. if v, changed := fastpathTV.DecMapBoolIntfV(*vp, true, d); changed {
  29946. *vp = v
  29947. }
  29948. return
  29949. }
  29950. fastpathTV.DecMapBoolIntfV(rv2i(rv).(map[bool]interface{}), false, d)
  29951. }
  29952. func (f fastpathT) DecMapBoolIntfX(vp *map[bool]interface{}, d *Decoder) {
  29953. if v, changed := f.DecMapBoolIntfV(*vp, true, d); changed {
  29954. *vp = v
  29955. }
  29956. }
  29957. func (_ fastpathT) DecMapBoolIntfV(v map[bool]interface{}, canChange bool,
  29958. d *Decoder) (_ map[bool]interface{}, changed bool) {
  29959. dd, esep := d.d, d.hh.hasElemSeparators()
  29960. containerLen := dd.ReadMapStart()
  29961. if canChange && v == nil {
  29962. xlen := decInferLen(containerLen, d.h.MaxInitLen, 17)
  29963. v = make(map[bool]interface{}, xlen)
  29964. changed = true
  29965. }
  29966. if containerLen == 0 {
  29967. dd.ReadMapEnd()
  29968. return v, changed
  29969. }
  29970. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  29971. var mk bool
  29972. var mv interface{}
  29973. hasLen := containerLen > 0
  29974. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29975. if esep {
  29976. dd.ReadMapElemKey()
  29977. }
  29978. mk = dd.DecodeBool()
  29979. if esep {
  29980. dd.ReadMapElemValue()
  29981. }
  29982. if dd.TryDecodeAsNil() {
  29983. if d.h.DeleteOnNilMapValue {
  29984. delete(v, mk)
  29985. } else {
  29986. v[mk] = nil
  29987. }
  29988. continue
  29989. }
  29990. if mapGet {
  29991. mv = v[mk]
  29992. } else {
  29993. mv = nil
  29994. }
  29995. d.decode(&mv)
  29996. if v != nil {
  29997. v[mk] = mv
  29998. }
  29999. }
  30000. dd.ReadMapEnd()
  30001. return v, changed
  30002. }
  30003. func (d *Decoder) fastpathDecMapBoolStringR(f *codecFnInfo, rv reflect.Value) {
  30004. if rv.Kind() == reflect.Ptr {
  30005. vp := rv2i(rv).(*map[bool]string)
  30006. if v, changed := fastpathTV.DecMapBoolStringV(*vp, true, d); changed {
  30007. *vp = v
  30008. }
  30009. return
  30010. }
  30011. fastpathTV.DecMapBoolStringV(rv2i(rv).(map[bool]string), false, d)
  30012. }
  30013. func (f fastpathT) DecMapBoolStringX(vp *map[bool]string, d *Decoder) {
  30014. if v, changed := f.DecMapBoolStringV(*vp, true, d); changed {
  30015. *vp = v
  30016. }
  30017. }
  30018. func (_ fastpathT) DecMapBoolStringV(v map[bool]string, canChange bool,
  30019. d *Decoder) (_ map[bool]string, changed bool) {
  30020. dd, esep := d.d, d.hh.hasElemSeparators()
  30021. containerLen := dd.ReadMapStart()
  30022. if canChange && v == nil {
  30023. xlen := decInferLen(containerLen, d.h.MaxInitLen, 17)
  30024. v = make(map[bool]string, xlen)
  30025. changed = true
  30026. }
  30027. if containerLen == 0 {
  30028. dd.ReadMapEnd()
  30029. return v, changed
  30030. }
  30031. var mk bool
  30032. var mv string
  30033. hasLen := containerLen > 0
  30034. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30035. if esep {
  30036. dd.ReadMapElemKey()
  30037. }
  30038. mk = dd.DecodeBool()
  30039. if esep {
  30040. dd.ReadMapElemValue()
  30041. }
  30042. if dd.TryDecodeAsNil() {
  30043. if d.h.DeleteOnNilMapValue {
  30044. delete(v, mk)
  30045. } else {
  30046. v[mk] = ""
  30047. }
  30048. continue
  30049. }
  30050. mv = dd.DecodeString()
  30051. if v != nil {
  30052. v[mk] = mv
  30053. }
  30054. }
  30055. dd.ReadMapEnd()
  30056. return v, changed
  30057. }
  30058. func (d *Decoder) fastpathDecMapBoolUintR(f *codecFnInfo, rv reflect.Value) {
  30059. if rv.Kind() == reflect.Ptr {
  30060. vp := rv2i(rv).(*map[bool]uint)
  30061. if v, changed := fastpathTV.DecMapBoolUintV(*vp, true, d); changed {
  30062. *vp = v
  30063. }
  30064. return
  30065. }
  30066. fastpathTV.DecMapBoolUintV(rv2i(rv).(map[bool]uint), false, d)
  30067. }
  30068. func (f fastpathT) DecMapBoolUintX(vp *map[bool]uint, d *Decoder) {
  30069. if v, changed := f.DecMapBoolUintV(*vp, true, d); changed {
  30070. *vp = v
  30071. }
  30072. }
  30073. func (_ fastpathT) DecMapBoolUintV(v map[bool]uint, canChange bool,
  30074. d *Decoder) (_ map[bool]uint, changed bool) {
  30075. dd, esep := d.d, d.hh.hasElemSeparators()
  30076. containerLen := dd.ReadMapStart()
  30077. if canChange && v == nil {
  30078. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  30079. v = make(map[bool]uint, xlen)
  30080. changed = true
  30081. }
  30082. if containerLen == 0 {
  30083. dd.ReadMapEnd()
  30084. return v, changed
  30085. }
  30086. var mk bool
  30087. var mv uint
  30088. hasLen := containerLen > 0
  30089. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30090. if esep {
  30091. dd.ReadMapElemKey()
  30092. }
  30093. mk = dd.DecodeBool()
  30094. if esep {
  30095. dd.ReadMapElemValue()
  30096. }
  30097. if dd.TryDecodeAsNil() {
  30098. if d.h.DeleteOnNilMapValue {
  30099. delete(v, mk)
  30100. } else {
  30101. v[mk] = 0
  30102. }
  30103. continue
  30104. }
  30105. mv = uint(dd.DecodeUint(uintBitsize))
  30106. if v != nil {
  30107. v[mk] = mv
  30108. }
  30109. }
  30110. dd.ReadMapEnd()
  30111. return v, changed
  30112. }
  30113. func (d *Decoder) fastpathDecMapBoolUint8R(f *codecFnInfo, rv reflect.Value) {
  30114. if rv.Kind() == reflect.Ptr {
  30115. vp := rv2i(rv).(*map[bool]uint8)
  30116. if v, changed := fastpathTV.DecMapBoolUint8V(*vp, true, d); changed {
  30117. *vp = v
  30118. }
  30119. return
  30120. }
  30121. fastpathTV.DecMapBoolUint8V(rv2i(rv).(map[bool]uint8), false, d)
  30122. }
  30123. func (f fastpathT) DecMapBoolUint8X(vp *map[bool]uint8, d *Decoder) {
  30124. if v, changed := f.DecMapBoolUint8V(*vp, true, d); changed {
  30125. *vp = v
  30126. }
  30127. }
  30128. func (_ fastpathT) DecMapBoolUint8V(v map[bool]uint8, canChange bool,
  30129. d *Decoder) (_ map[bool]uint8, changed bool) {
  30130. dd, esep := d.d, d.hh.hasElemSeparators()
  30131. containerLen := dd.ReadMapStart()
  30132. if canChange && v == nil {
  30133. xlen := decInferLen(containerLen, d.h.MaxInitLen, 2)
  30134. v = make(map[bool]uint8, xlen)
  30135. changed = true
  30136. }
  30137. if containerLen == 0 {
  30138. dd.ReadMapEnd()
  30139. return v, changed
  30140. }
  30141. var mk bool
  30142. var mv uint8
  30143. hasLen := containerLen > 0
  30144. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30145. if esep {
  30146. dd.ReadMapElemKey()
  30147. }
  30148. mk = dd.DecodeBool()
  30149. if esep {
  30150. dd.ReadMapElemValue()
  30151. }
  30152. if dd.TryDecodeAsNil() {
  30153. if d.h.DeleteOnNilMapValue {
  30154. delete(v, mk)
  30155. } else {
  30156. v[mk] = 0
  30157. }
  30158. continue
  30159. }
  30160. mv = uint8(dd.DecodeUint(8))
  30161. if v != nil {
  30162. v[mk] = mv
  30163. }
  30164. }
  30165. dd.ReadMapEnd()
  30166. return v, changed
  30167. }
  30168. func (d *Decoder) fastpathDecMapBoolUint16R(f *codecFnInfo, rv reflect.Value) {
  30169. if rv.Kind() == reflect.Ptr {
  30170. vp := rv2i(rv).(*map[bool]uint16)
  30171. if v, changed := fastpathTV.DecMapBoolUint16V(*vp, true, d); changed {
  30172. *vp = v
  30173. }
  30174. return
  30175. }
  30176. fastpathTV.DecMapBoolUint16V(rv2i(rv).(map[bool]uint16), false, d)
  30177. }
  30178. func (f fastpathT) DecMapBoolUint16X(vp *map[bool]uint16, d *Decoder) {
  30179. if v, changed := f.DecMapBoolUint16V(*vp, true, d); changed {
  30180. *vp = v
  30181. }
  30182. }
  30183. func (_ fastpathT) DecMapBoolUint16V(v map[bool]uint16, canChange bool,
  30184. d *Decoder) (_ map[bool]uint16, changed bool) {
  30185. dd, esep := d.d, d.hh.hasElemSeparators()
  30186. containerLen := dd.ReadMapStart()
  30187. if canChange && v == nil {
  30188. xlen := decInferLen(containerLen, d.h.MaxInitLen, 3)
  30189. v = make(map[bool]uint16, xlen)
  30190. changed = true
  30191. }
  30192. if containerLen == 0 {
  30193. dd.ReadMapEnd()
  30194. return v, changed
  30195. }
  30196. var mk bool
  30197. var mv uint16
  30198. hasLen := containerLen > 0
  30199. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30200. if esep {
  30201. dd.ReadMapElemKey()
  30202. }
  30203. mk = dd.DecodeBool()
  30204. if esep {
  30205. dd.ReadMapElemValue()
  30206. }
  30207. if dd.TryDecodeAsNil() {
  30208. if d.h.DeleteOnNilMapValue {
  30209. delete(v, mk)
  30210. } else {
  30211. v[mk] = 0
  30212. }
  30213. continue
  30214. }
  30215. mv = uint16(dd.DecodeUint(16))
  30216. if v != nil {
  30217. v[mk] = mv
  30218. }
  30219. }
  30220. dd.ReadMapEnd()
  30221. return v, changed
  30222. }
  30223. func (d *Decoder) fastpathDecMapBoolUint32R(f *codecFnInfo, rv reflect.Value) {
  30224. if rv.Kind() == reflect.Ptr {
  30225. vp := rv2i(rv).(*map[bool]uint32)
  30226. if v, changed := fastpathTV.DecMapBoolUint32V(*vp, true, d); changed {
  30227. *vp = v
  30228. }
  30229. return
  30230. }
  30231. fastpathTV.DecMapBoolUint32V(rv2i(rv).(map[bool]uint32), false, d)
  30232. }
  30233. func (f fastpathT) DecMapBoolUint32X(vp *map[bool]uint32, d *Decoder) {
  30234. if v, changed := f.DecMapBoolUint32V(*vp, true, d); changed {
  30235. *vp = v
  30236. }
  30237. }
  30238. func (_ fastpathT) DecMapBoolUint32V(v map[bool]uint32, canChange bool,
  30239. d *Decoder) (_ map[bool]uint32, changed bool) {
  30240. dd, esep := d.d, d.hh.hasElemSeparators()
  30241. containerLen := dd.ReadMapStart()
  30242. if canChange && v == nil {
  30243. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  30244. v = make(map[bool]uint32, xlen)
  30245. changed = true
  30246. }
  30247. if containerLen == 0 {
  30248. dd.ReadMapEnd()
  30249. return v, changed
  30250. }
  30251. var mk bool
  30252. var mv uint32
  30253. hasLen := containerLen > 0
  30254. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30255. if esep {
  30256. dd.ReadMapElemKey()
  30257. }
  30258. mk = dd.DecodeBool()
  30259. if esep {
  30260. dd.ReadMapElemValue()
  30261. }
  30262. if dd.TryDecodeAsNil() {
  30263. if d.h.DeleteOnNilMapValue {
  30264. delete(v, mk)
  30265. } else {
  30266. v[mk] = 0
  30267. }
  30268. continue
  30269. }
  30270. mv = uint32(dd.DecodeUint(32))
  30271. if v != nil {
  30272. v[mk] = mv
  30273. }
  30274. }
  30275. dd.ReadMapEnd()
  30276. return v, changed
  30277. }
  30278. func (d *Decoder) fastpathDecMapBoolUint64R(f *codecFnInfo, rv reflect.Value) {
  30279. if rv.Kind() == reflect.Ptr {
  30280. vp := rv2i(rv).(*map[bool]uint64)
  30281. if v, changed := fastpathTV.DecMapBoolUint64V(*vp, true, d); changed {
  30282. *vp = v
  30283. }
  30284. return
  30285. }
  30286. fastpathTV.DecMapBoolUint64V(rv2i(rv).(map[bool]uint64), false, d)
  30287. }
  30288. func (f fastpathT) DecMapBoolUint64X(vp *map[bool]uint64, d *Decoder) {
  30289. if v, changed := f.DecMapBoolUint64V(*vp, true, d); changed {
  30290. *vp = v
  30291. }
  30292. }
  30293. func (_ fastpathT) DecMapBoolUint64V(v map[bool]uint64, canChange bool,
  30294. d *Decoder) (_ map[bool]uint64, changed bool) {
  30295. dd, esep := d.d, d.hh.hasElemSeparators()
  30296. containerLen := dd.ReadMapStart()
  30297. if canChange && v == nil {
  30298. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  30299. v = make(map[bool]uint64, xlen)
  30300. changed = true
  30301. }
  30302. if containerLen == 0 {
  30303. dd.ReadMapEnd()
  30304. return v, changed
  30305. }
  30306. var mk bool
  30307. var mv uint64
  30308. hasLen := containerLen > 0
  30309. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30310. if esep {
  30311. dd.ReadMapElemKey()
  30312. }
  30313. mk = dd.DecodeBool()
  30314. if esep {
  30315. dd.ReadMapElemValue()
  30316. }
  30317. if dd.TryDecodeAsNil() {
  30318. if d.h.DeleteOnNilMapValue {
  30319. delete(v, mk)
  30320. } else {
  30321. v[mk] = 0
  30322. }
  30323. continue
  30324. }
  30325. mv = dd.DecodeUint(64)
  30326. if v != nil {
  30327. v[mk] = mv
  30328. }
  30329. }
  30330. dd.ReadMapEnd()
  30331. return v, changed
  30332. }
  30333. func (d *Decoder) fastpathDecMapBoolUintptrR(f *codecFnInfo, rv reflect.Value) {
  30334. if rv.Kind() == reflect.Ptr {
  30335. vp := rv2i(rv).(*map[bool]uintptr)
  30336. if v, changed := fastpathTV.DecMapBoolUintptrV(*vp, true, d); changed {
  30337. *vp = v
  30338. }
  30339. return
  30340. }
  30341. fastpathTV.DecMapBoolUintptrV(rv2i(rv).(map[bool]uintptr), false, d)
  30342. }
  30343. func (f fastpathT) DecMapBoolUintptrX(vp *map[bool]uintptr, d *Decoder) {
  30344. if v, changed := f.DecMapBoolUintptrV(*vp, true, d); changed {
  30345. *vp = v
  30346. }
  30347. }
  30348. func (_ fastpathT) DecMapBoolUintptrV(v map[bool]uintptr, canChange bool,
  30349. d *Decoder) (_ map[bool]uintptr, changed bool) {
  30350. dd, esep := d.d, d.hh.hasElemSeparators()
  30351. containerLen := dd.ReadMapStart()
  30352. if canChange && v == nil {
  30353. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  30354. v = make(map[bool]uintptr, xlen)
  30355. changed = true
  30356. }
  30357. if containerLen == 0 {
  30358. dd.ReadMapEnd()
  30359. return v, changed
  30360. }
  30361. var mk bool
  30362. var mv uintptr
  30363. hasLen := containerLen > 0
  30364. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30365. if esep {
  30366. dd.ReadMapElemKey()
  30367. }
  30368. mk = dd.DecodeBool()
  30369. if esep {
  30370. dd.ReadMapElemValue()
  30371. }
  30372. if dd.TryDecodeAsNil() {
  30373. if d.h.DeleteOnNilMapValue {
  30374. delete(v, mk)
  30375. } else {
  30376. v[mk] = 0
  30377. }
  30378. continue
  30379. }
  30380. mv = uintptr(dd.DecodeUint(uintBitsize))
  30381. if v != nil {
  30382. v[mk] = mv
  30383. }
  30384. }
  30385. dd.ReadMapEnd()
  30386. return v, changed
  30387. }
  30388. func (d *Decoder) fastpathDecMapBoolIntR(f *codecFnInfo, rv reflect.Value) {
  30389. if rv.Kind() == reflect.Ptr {
  30390. vp := rv2i(rv).(*map[bool]int)
  30391. if v, changed := fastpathTV.DecMapBoolIntV(*vp, true, d); changed {
  30392. *vp = v
  30393. }
  30394. return
  30395. }
  30396. fastpathTV.DecMapBoolIntV(rv2i(rv).(map[bool]int), false, d)
  30397. }
  30398. func (f fastpathT) DecMapBoolIntX(vp *map[bool]int, d *Decoder) {
  30399. if v, changed := f.DecMapBoolIntV(*vp, true, d); changed {
  30400. *vp = v
  30401. }
  30402. }
  30403. func (_ fastpathT) DecMapBoolIntV(v map[bool]int, canChange bool,
  30404. d *Decoder) (_ map[bool]int, changed bool) {
  30405. dd, esep := d.d, d.hh.hasElemSeparators()
  30406. containerLen := dd.ReadMapStart()
  30407. if canChange && v == nil {
  30408. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  30409. v = make(map[bool]int, xlen)
  30410. changed = true
  30411. }
  30412. if containerLen == 0 {
  30413. dd.ReadMapEnd()
  30414. return v, changed
  30415. }
  30416. var mk bool
  30417. var mv int
  30418. hasLen := containerLen > 0
  30419. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30420. if esep {
  30421. dd.ReadMapElemKey()
  30422. }
  30423. mk = dd.DecodeBool()
  30424. if esep {
  30425. dd.ReadMapElemValue()
  30426. }
  30427. if dd.TryDecodeAsNil() {
  30428. if d.h.DeleteOnNilMapValue {
  30429. delete(v, mk)
  30430. } else {
  30431. v[mk] = 0
  30432. }
  30433. continue
  30434. }
  30435. mv = int(dd.DecodeInt(intBitsize))
  30436. if v != nil {
  30437. v[mk] = mv
  30438. }
  30439. }
  30440. dd.ReadMapEnd()
  30441. return v, changed
  30442. }
  30443. func (d *Decoder) fastpathDecMapBoolInt8R(f *codecFnInfo, rv reflect.Value) {
  30444. if rv.Kind() == reflect.Ptr {
  30445. vp := rv2i(rv).(*map[bool]int8)
  30446. if v, changed := fastpathTV.DecMapBoolInt8V(*vp, true, d); changed {
  30447. *vp = v
  30448. }
  30449. return
  30450. }
  30451. fastpathTV.DecMapBoolInt8V(rv2i(rv).(map[bool]int8), false, d)
  30452. }
  30453. func (f fastpathT) DecMapBoolInt8X(vp *map[bool]int8, d *Decoder) {
  30454. if v, changed := f.DecMapBoolInt8V(*vp, true, d); changed {
  30455. *vp = v
  30456. }
  30457. }
  30458. func (_ fastpathT) DecMapBoolInt8V(v map[bool]int8, canChange bool,
  30459. d *Decoder) (_ map[bool]int8, changed bool) {
  30460. dd, esep := d.d, d.hh.hasElemSeparators()
  30461. containerLen := dd.ReadMapStart()
  30462. if canChange && v == nil {
  30463. xlen := decInferLen(containerLen, d.h.MaxInitLen, 2)
  30464. v = make(map[bool]int8, xlen)
  30465. changed = true
  30466. }
  30467. if containerLen == 0 {
  30468. dd.ReadMapEnd()
  30469. return v, changed
  30470. }
  30471. var mk bool
  30472. var mv int8
  30473. hasLen := containerLen > 0
  30474. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30475. if esep {
  30476. dd.ReadMapElemKey()
  30477. }
  30478. mk = dd.DecodeBool()
  30479. if esep {
  30480. dd.ReadMapElemValue()
  30481. }
  30482. if dd.TryDecodeAsNil() {
  30483. if d.h.DeleteOnNilMapValue {
  30484. delete(v, mk)
  30485. } else {
  30486. v[mk] = 0
  30487. }
  30488. continue
  30489. }
  30490. mv = int8(dd.DecodeInt(8))
  30491. if v != nil {
  30492. v[mk] = mv
  30493. }
  30494. }
  30495. dd.ReadMapEnd()
  30496. return v, changed
  30497. }
  30498. func (d *Decoder) fastpathDecMapBoolInt16R(f *codecFnInfo, rv reflect.Value) {
  30499. if rv.Kind() == reflect.Ptr {
  30500. vp := rv2i(rv).(*map[bool]int16)
  30501. if v, changed := fastpathTV.DecMapBoolInt16V(*vp, true, d); changed {
  30502. *vp = v
  30503. }
  30504. return
  30505. }
  30506. fastpathTV.DecMapBoolInt16V(rv2i(rv).(map[bool]int16), false, d)
  30507. }
  30508. func (f fastpathT) DecMapBoolInt16X(vp *map[bool]int16, d *Decoder) {
  30509. if v, changed := f.DecMapBoolInt16V(*vp, true, d); changed {
  30510. *vp = v
  30511. }
  30512. }
  30513. func (_ fastpathT) DecMapBoolInt16V(v map[bool]int16, canChange bool,
  30514. d *Decoder) (_ map[bool]int16, changed bool) {
  30515. dd, esep := d.d, d.hh.hasElemSeparators()
  30516. containerLen := dd.ReadMapStart()
  30517. if canChange && v == nil {
  30518. xlen := decInferLen(containerLen, d.h.MaxInitLen, 3)
  30519. v = make(map[bool]int16, xlen)
  30520. changed = true
  30521. }
  30522. if containerLen == 0 {
  30523. dd.ReadMapEnd()
  30524. return v, changed
  30525. }
  30526. var mk bool
  30527. var mv int16
  30528. hasLen := containerLen > 0
  30529. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30530. if esep {
  30531. dd.ReadMapElemKey()
  30532. }
  30533. mk = dd.DecodeBool()
  30534. if esep {
  30535. dd.ReadMapElemValue()
  30536. }
  30537. if dd.TryDecodeAsNil() {
  30538. if d.h.DeleteOnNilMapValue {
  30539. delete(v, mk)
  30540. } else {
  30541. v[mk] = 0
  30542. }
  30543. continue
  30544. }
  30545. mv = int16(dd.DecodeInt(16))
  30546. if v != nil {
  30547. v[mk] = mv
  30548. }
  30549. }
  30550. dd.ReadMapEnd()
  30551. return v, changed
  30552. }
  30553. func (d *Decoder) fastpathDecMapBoolInt32R(f *codecFnInfo, rv reflect.Value) {
  30554. if rv.Kind() == reflect.Ptr {
  30555. vp := rv2i(rv).(*map[bool]int32)
  30556. if v, changed := fastpathTV.DecMapBoolInt32V(*vp, true, d); changed {
  30557. *vp = v
  30558. }
  30559. return
  30560. }
  30561. fastpathTV.DecMapBoolInt32V(rv2i(rv).(map[bool]int32), false, d)
  30562. }
  30563. func (f fastpathT) DecMapBoolInt32X(vp *map[bool]int32, d *Decoder) {
  30564. if v, changed := f.DecMapBoolInt32V(*vp, true, d); changed {
  30565. *vp = v
  30566. }
  30567. }
  30568. func (_ fastpathT) DecMapBoolInt32V(v map[bool]int32, canChange bool,
  30569. d *Decoder) (_ map[bool]int32, changed bool) {
  30570. dd, esep := d.d, d.hh.hasElemSeparators()
  30571. containerLen := dd.ReadMapStart()
  30572. if canChange && v == nil {
  30573. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  30574. v = make(map[bool]int32, xlen)
  30575. changed = true
  30576. }
  30577. if containerLen == 0 {
  30578. dd.ReadMapEnd()
  30579. return v, changed
  30580. }
  30581. var mk bool
  30582. var mv int32
  30583. hasLen := containerLen > 0
  30584. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30585. if esep {
  30586. dd.ReadMapElemKey()
  30587. }
  30588. mk = dd.DecodeBool()
  30589. if esep {
  30590. dd.ReadMapElemValue()
  30591. }
  30592. if dd.TryDecodeAsNil() {
  30593. if d.h.DeleteOnNilMapValue {
  30594. delete(v, mk)
  30595. } else {
  30596. v[mk] = 0
  30597. }
  30598. continue
  30599. }
  30600. mv = int32(dd.DecodeInt(32))
  30601. if v != nil {
  30602. v[mk] = mv
  30603. }
  30604. }
  30605. dd.ReadMapEnd()
  30606. return v, changed
  30607. }
  30608. func (d *Decoder) fastpathDecMapBoolInt64R(f *codecFnInfo, rv reflect.Value) {
  30609. if rv.Kind() == reflect.Ptr {
  30610. vp := rv2i(rv).(*map[bool]int64)
  30611. if v, changed := fastpathTV.DecMapBoolInt64V(*vp, true, d); changed {
  30612. *vp = v
  30613. }
  30614. return
  30615. }
  30616. fastpathTV.DecMapBoolInt64V(rv2i(rv).(map[bool]int64), false, d)
  30617. }
  30618. func (f fastpathT) DecMapBoolInt64X(vp *map[bool]int64, d *Decoder) {
  30619. if v, changed := f.DecMapBoolInt64V(*vp, true, d); changed {
  30620. *vp = v
  30621. }
  30622. }
  30623. func (_ fastpathT) DecMapBoolInt64V(v map[bool]int64, canChange bool,
  30624. d *Decoder) (_ map[bool]int64, changed bool) {
  30625. dd, esep := d.d, d.hh.hasElemSeparators()
  30626. containerLen := dd.ReadMapStart()
  30627. if canChange && v == nil {
  30628. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  30629. v = make(map[bool]int64, xlen)
  30630. changed = true
  30631. }
  30632. if containerLen == 0 {
  30633. dd.ReadMapEnd()
  30634. return v, changed
  30635. }
  30636. var mk bool
  30637. var mv int64
  30638. hasLen := containerLen > 0
  30639. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30640. if esep {
  30641. dd.ReadMapElemKey()
  30642. }
  30643. mk = dd.DecodeBool()
  30644. if esep {
  30645. dd.ReadMapElemValue()
  30646. }
  30647. if dd.TryDecodeAsNil() {
  30648. if d.h.DeleteOnNilMapValue {
  30649. delete(v, mk)
  30650. } else {
  30651. v[mk] = 0
  30652. }
  30653. continue
  30654. }
  30655. mv = dd.DecodeInt(64)
  30656. if v != nil {
  30657. v[mk] = mv
  30658. }
  30659. }
  30660. dd.ReadMapEnd()
  30661. return v, changed
  30662. }
  30663. func (d *Decoder) fastpathDecMapBoolFloat32R(f *codecFnInfo, rv reflect.Value) {
  30664. if rv.Kind() == reflect.Ptr {
  30665. vp := rv2i(rv).(*map[bool]float32)
  30666. if v, changed := fastpathTV.DecMapBoolFloat32V(*vp, true, d); changed {
  30667. *vp = v
  30668. }
  30669. return
  30670. }
  30671. fastpathTV.DecMapBoolFloat32V(rv2i(rv).(map[bool]float32), false, d)
  30672. }
  30673. func (f fastpathT) DecMapBoolFloat32X(vp *map[bool]float32, d *Decoder) {
  30674. if v, changed := f.DecMapBoolFloat32V(*vp, true, d); changed {
  30675. *vp = v
  30676. }
  30677. }
  30678. func (_ fastpathT) DecMapBoolFloat32V(v map[bool]float32, canChange bool,
  30679. d *Decoder) (_ map[bool]float32, changed bool) {
  30680. dd, esep := d.d, d.hh.hasElemSeparators()
  30681. containerLen := dd.ReadMapStart()
  30682. if canChange && v == nil {
  30683. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  30684. v = make(map[bool]float32, xlen)
  30685. changed = true
  30686. }
  30687. if containerLen == 0 {
  30688. dd.ReadMapEnd()
  30689. return v, changed
  30690. }
  30691. var mk bool
  30692. var mv float32
  30693. hasLen := containerLen > 0
  30694. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30695. if esep {
  30696. dd.ReadMapElemKey()
  30697. }
  30698. mk = dd.DecodeBool()
  30699. if esep {
  30700. dd.ReadMapElemValue()
  30701. }
  30702. if dd.TryDecodeAsNil() {
  30703. if d.h.DeleteOnNilMapValue {
  30704. delete(v, mk)
  30705. } else {
  30706. v[mk] = 0
  30707. }
  30708. continue
  30709. }
  30710. mv = float32(dd.DecodeFloat(true))
  30711. if v != nil {
  30712. v[mk] = mv
  30713. }
  30714. }
  30715. dd.ReadMapEnd()
  30716. return v, changed
  30717. }
  30718. func (d *Decoder) fastpathDecMapBoolFloat64R(f *codecFnInfo, rv reflect.Value) {
  30719. if rv.Kind() == reflect.Ptr {
  30720. vp := rv2i(rv).(*map[bool]float64)
  30721. if v, changed := fastpathTV.DecMapBoolFloat64V(*vp, true, d); changed {
  30722. *vp = v
  30723. }
  30724. return
  30725. }
  30726. fastpathTV.DecMapBoolFloat64V(rv2i(rv).(map[bool]float64), false, d)
  30727. }
  30728. func (f fastpathT) DecMapBoolFloat64X(vp *map[bool]float64, d *Decoder) {
  30729. if v, changed := f.DecMapBoolFloat64V(*vp, true, d); changed {
  30730. *vp = v
  30731. }
  30732. }
  30733. func (_ fastpathT) DecMapBoolFloat64V(v map[bool]float64, canChange bool,
  30734. d *Decoder) (_ map[bool]float64, changed bool) {
  30735. dd, esep := d.d, d.hh.hasElemSeparators()
  30736. containerLen := dd.ReadMapStart()
  30737. if canChange && v == nil {
  30738. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  30739. v = make(map[bool]float64, xlen)
  30740. changed = true
  30741. }
  30742. if containerLen == 0 {
  30743. dd.ReadMapEnd()
  30744. return v, changed
  30745. }
  30746. var mk bool
  30747. var mv float64
  30748. hasLen := containerLen > 0
  30749. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30750. if esep {
  30751. dd.ReadMapElemKey()
  30752. }
  30753. mk = dd.DecodeBool()
  30754. if esep {
  30755. dd.ReadMapElemValue()
  30756. }
  30757. if dd.TryDecodeAsNil() {
  30758. if d.h.DeleteOnNilMapValue {
  30759. delete(v, mk)
  30760. } else {
  30761. v[mk] = 0
  30762. }
  30763. continue
  30764. }
  30765. mv = dd.DecodeFloat(false)
  30766. if v != nil {
  30767. v[mk] = mv
  30768. }
  30769. }
  30770. dd.ReadMapEnd()
  30771. return v, changed
  30772. }
  30773. func (d *Decoder) fastpathDecMapBoolBoolR(f *codecFnInfo, rv reflect.Value) {
  30774. if rv.Kind() == reflect.Ptr {
  30775. vp := rv2i(rv).(*map[bool]bool)
  30776. if v, changed := fastpathTV.DecMapBoolBoolV(*vp, true, d); changed {
  30777. *vp = v
  30778. }
  30779. return
  30780. }
  30781. fastpathTV.DecMapBoolBoolV(rv2i(rv).(map[bool]bool), false, d)
  30782. }
  30783. func (f fastpathT) DecMapBoolBoolX(vp *map[bool]bool, d *Decoder) {
  30784. if v, changed := f.DecMapBoolBoolV(*vp, true, d); changed {
  30785. *vp = v
  30786. }
  30787. }
  30788. func (_ fastpathT) DecMapBoolBoolV(v map[bool]bool, canChange bool,
  30789. d *Decoder) (_ map[bool]bool, changed bool) {
  30790. dd, esep := d.d, d.hh.hasElemSeparators()
  30791. containerLen := dd.ReadMapStart()
  30792. if canChange && v == nil {
  30793. xlen := decInferLen(containerLen, d.h.MaxInitLen, 2)
  30794. v = make(map[bool]bool, xlen)
  30795. changed = true
  30796. }
  30797. if containerLen == 0 {
  30798. dd.ReadMapEnd()
  30799. return v, changed
  30800. }
  30801. var mk bool
  30802. var mv bool
  30803. hasLen := containerLen > 0
  30804. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30805. if esep {
  30806. dd.ReadMapElemKey()
  30807. }
  30808. mk = dd.DecodeBool()
  30809. if esep {
  30810. dd.ReadMapElemValue()
  30811. }
  30812. if dd.TryDecodeAsNil() {
  30813. if d.h.DeleteOnNilMapValue {
  30814. delete(v, mk)
  30815. } else {
  30816. v[mk] = false
  30817. }
  30818. continue
  30819. }
  30820. mv = dd.DecodeBool()
  30821. if v != nil {
  30822. v[mk] = mv
  30823. }
  30824. }
  30825. dd.ReadMapEnd()
  30826. return v, changed
  30827. }