1
0

010-xml-parser-expat-use-ppport.h 191 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626462746284629463046314632463346344635463646374638463946404641464246434644464546464647464846494650465146524653465446554656465746584659466046614662466346644665466646674668466946704671467246734674467546764677467846794680468146824683468446854686468746884689469046914692469346944695469646974698469947004701470247034704470547064707470847094710471147124713471447154716471747184719472047214722472347244725472647274728472947304731473247334734473547364737473847394740474147424743474447454746474747484749475047514752475347544755475647574758475947604761476247634764476547664767476847694770477147724773477447754776477747784779478047814782478347844785478647874788478947904791479247934794479547964797479847994800480148024803480448054806480748084809481048114812481348144815481648174818481948204821482248234824482548264827482848294830483148324833483448354836483748384839484048414842484348444845484648474848484948504851485248534854485548564857485848594860486148624863486448654866486748684869487048714872487348744875487648774878487948804881488248834884488548864887488848894890489148924893489448954896489748984899490049014902490349044905490649074908490949104911491249134914491549164917491849194920492149224923492449254926492749284929493049314932493349344935493649374938493949404941494249434944494549464947494849494950495149524953495449554956495749584959496049614962496349644965496649674968496949704971497249734974497549764977497849794980498149824983498449854986498749884989499049914992499349944995499649974998499950005001500250035004500550065007500850095010501150125013501450155016501750185019502050215022502350245025502650275028502950305031503250335034503550365037503850395040504150425043504450455046504750485049505050515052505350545055505650575058505950605061506250635064506550665067506850695070507150725073507450755076507750785079508050815082508350845085508650875088508950905091509250935094509550965097509850995100510151025103510451055106510751085109511051115112511351145115511651175118511951205121512251235124512551265127512851295130513151325133513451355136513751385139514051415142514351445145514651475148514951505151515251535154515551565157515851595160516151625163516451655166516751685169517051715172517351745175517651775178517951805181518251835184518551865187518851895190519151925193519451955196519751985199520052015202520352045205520652075208520952105211521252135214521552165217521852195220522152225223522452255226522752285229523052315232523352345235523652375238523952405241524252435244524552465247524852495250525152525253525452555256525752585259526052615262526352645265526652675268526952705271527252735274527552765277527852795280528152825283528452855286528752885289529052915292529352945295529652975298529953005301530253035304530553065307530853095310531153125313531453155316531753185319532053215322532353245325532653275328532953305331533253335334533553365337533853395340534153425343534453455346534753485349535053515352535353545355535653575358535953605361536253635364536553665367536853695370537153725373537453755376537753785379538053815382538353845385538653875388538953905391539253935394539553965397539853995400540154025403540454055406540754085409541054115412541354145415541654175418541954205421542254235424542554265427542854295430543154325433543454355436543754385439544054415442544354445445544654475448544954505451545254535454545554565457545854595460546154625463546454655466546754685469547054715472547354745475547654775478547954805481548254835484548554865487548854895490549154925493549454955496549754985499550055015502550355045505550655075508550955105511551255135514551555165517551855195520552155225523552455255526552755285529553055315532553355345535553655375538553955405541554255435544554555465547554855495550555155525553555455555556555755585559556055615562556355645565556655675568556955705571557255735574557555765577557855795580558155825583558455855586558755885589559055915592559355945595559655975598559956005601560256035604560556065607560856095610561156125613561456155616561756185619562056215622562356245625562656275628562956305631563256335634563556365637563856395640564156425643564456455646564756485649565056515652565356545655565656575658565956605661566256635664566556665667566856695670567156725673567456755676567756785679568056815682568356845685568656875688568956905691569256935694569556965697569856995700570157025703570457055706570757085709571057115712571357145715571657175718571957205721572257235724572557265727572857295730573157325733573457355736573757385739574057415742574357445745574657475748574957505751575257535754575557565757575857595760576157625763576457655766576757685769577057715772577357745775577657775778577957805781578257835784578557865787578857895790579157925793579457955796579757985799580058015802580358045805580658075808580958105811581258135814581558165817581858195820582158225823582458255826582758285829583058315832583358345835583658375838583958405841584258435844584558465847584858495850585158525853585458555856585758585859586058615862586358645865586658675868586958705871587258735874587558765877587858795880588158825883588458855886588758885889589058915892589358945895589658975898589959005901590259035904590559065907590859095910591159125913591459155916591759185919592059215922592359245925592659275928592959305931593259335934593559365937593859395940594159425943594459455946594759485949595059515952595359545955595659575958595959605961596259635964596559665967596859695970597159725973597459755976597759785979598059815982598359845985598659875988598959905991599259935994599559965997599859996000600160026003600460056006600760086009601060116012601360146015601660176018601960206021602260236024602560266027602860296030603160326033603460356036603760386039604060416042604360446045604660476048604960506051605260536054605560566057605860596060606160626063606460656066606760686069607060716072607360746075607660776078607960806081608260836084608560866087608860896090609160926093609460956096609760986099610061016102610361046105610661076108610961106111611261136114611561166117611861196120612161226123612461256126612761286129613061316132613361346135613661376138613961406141614261436144614561466147614861496150615161526153615461556156615761586159616061616162616361646165616661676168616961706171617261736174617561766177617861796180618161826183618461856186618761886189619061916192619361946195619661976198619962006201620262036204620562066207620862096210621162126213621462156216621762186219622062216222622362246225622662276228622962306231623262336234623562366237623862396240624162426243624462456246624762486249625062516252625362546255625662576258625962606261626262636264626562666267626862696270627162726273627462756276627762786279628062816282628362846285628662876288628962906291629262936294629562966297629862996300630163026303630463056306630763086309631063116312631363146315631663176318631963206321632263236324632563266327632863296330633163326333633463356336633763386339634063416342634363446345634663476348634963506351635263536354635563566357635863596360636163626363636463656366636763686369637063716372637363746375637663776378637963806381638263836384638563866387638863896390639163926393639463956396639763986399640064016402640364046405640664076408640964106411641264136414641564166417641864196420642164226423642464256426642764286429643064316432643364346435643664376438643964406441644264436444644564466447644864496450645164526453645464556456645764586459646064616462646364646465646664676468646964706471647264736474647564766477647864796480648164826483648464856486648764886489649064916492649364946495649664976498649965006501650265036504650565066507650865096510651165126513651465156516651765186519652065216522652365246525652665276528652965306531653265336534653565366537653865396540654165426543654465456546654765486549655065516552655365546555655665576558655965606561656265636564656565666567656865696570657165726573657465756576657765786579658065816582658365846585658665876588658965906591659265936594659565966597659865996600660166026603660466056606660766086609661066116612661366146615661666176618661966206621662266236624662566266627662866296630663166326633663466356636663766386639664066416642664366446645664666476648664966506651665266536654665566566657665866596660666166626663666466656666666766686669667066716672667366746675667666776678667966806681668266836684668566866687668866896690669166926693669466956696669766986699670067016702670367046705670667076708670967106711671267136714671567166717671867196720672167226723672467256726672767286729673067316732673367346735673667376738673967406741674267436744674567466747674867496750675167526753675467556756675767586759676067616762676367646765676667676768676967706771677267736774677567766777677867796780678167826783678467856786678767886789679067916792679367946795679667976798679968006801680268036804680568066807680868096810681168126813681468156816681768186819682068216822682368246825682668276828682968306831683268336834683568366837683868396840684168426843684468456846684768486849685068516852685368546855685668576858685968606861686268636864686568666867686868696870687168726873687468756876687768786879688068816882688368846885688668876888688968906891689268936894689568966897689868996900690169026903690469056906690769086909691069116912691369146915691669176918691969206921692269236924692569266927692869296930693169326933693469356936693769386939694069416942694369446945694669476948694969506951695269536954695569566957695869596960696169626963696469656966696769686969697069716972697369746975697669776978697969806981698269836984698569866987698869896990699169926993699469956996699769986999700070017002700370047005700670077008700970107011701270137014701570167017701870197020702170227023702470257026702770287029703070317032703370347035703670377038703970407041704270437044704570467047704870497050705170527053705470557056705770587059706070617062706370647065706670677068706970707071707270737074707570767077707870797080708170827083708470857086708770887089709070917092709370947095709670977098709971007101710271037104710571067107710871097110711171127113711471157116711771187119712071217122712371247125712671277128712971307131713271337134713571367137713871397140714171427143714471457146714771487149715071517152715371547155715671577158715971607161716271637164716571667167716871697170717171727173717471757176717771787179718071817182718371847185718671877188718971907191719271937194719571967197719871997200720172027203720472057206720772087209721072117212721372147215721672177218721972207221722272237224722572267227722872297230723172327233723472357236723772387239724072417242724372447245724672477248724972507251725272537254725572567257725872597260726172627263726472657266726772687269727072717272727372747275727672777278727972807281728272837284728572867287728872897290729172927293729472957296729772987299730073017302730373047305730673077308730973107311731273137314731573167317731873197320732173227323732473257326732773287329733073317332733373347335733673377338733973407341734273437344734573467347734873497350735173527353735473557356735773587359736073617362736373647365736673677368736973707371737273737374737573767377737873797380738173827383738473857386738773887389739073917392739373947395739673977398739974007401740274037404740574067407740874097410741174127413741474157416741774187419742074217422742374247425742674277428742974307431743274337434743574367437743874397440744174427443744474457446744774487449745074517452745374547455745674577458745974607461746274637464746574667467746874697470747174727473747474757476
  1. --- a/Expat/Expat.xs
  2. +++ b/Expat/Expat.xs
  3. @@ -20,17 +20,7 @@
  4. #include "patchlevel.h"
  5. #include "encoding.h"
  6. -
  7. -/* Version 5.005_5x (Development version for 5.006) doesn't like sv_...
  8. - anymore, but 5.004 doesn't know about PL_sv..
  9. - Don't want to push up required version just for this. */
  10. -
  11. -#if PATCHLEVEL < 5
  12. -#define PL_sv_undef sv_undef
  13. -#define PL_sv_no sv_no
  14. -#define PL_sv_yes sv_yes
  15. -#define PL_na na
  16. -#endif
  17. +#include "ppport.h"
  18. #define BUFSIZE 32768
  19. --- /dev/null
  20. +++ b/Expat/ppport.h
  21. @@ -0,0 +1,7452 @@
  22. +#if 0
  23. +<<'SKIP';
  24. +#endif
  25. +/*
  26. +----------------------------------------------------------------------
  27. +
  28. + ppport.h -- Perl/Pollution/Portability Version 3.21
  29. +
  30. + Automatically created by Devel::PPPort running under perl 5.020002.
  31. +
  32. + Do NOT edit this file directly! -- Edit PPPort_pm.PL and the
  33. + includes in parts/inc/ instead.
  34. +
  35. + Use 'perldoc ppport.h' to view the documentation below.
  36. +
  37. +----------------------------------------------------------------------
  38. +
  39. +SKIP
  40. +
  41. +=pod
  42. +
  43. +=head1 NAME
  44. +
  45. +ppport.h - Perl/Pollution/Portability version 3.21
  46. +
  47. +=head1 SYNOPSIS
  48. +
  49. + perl ppport.h [options] [source files]
  50. +
  51. + Searches current directory for files if no [source files] are given
  52. +
  53. + --help show short help
  54. +
  55. + --version show version
  56. +
  57. + --patch=file write one patch file with changes
  58. + --copy=suffix write changed copies with suffix
  59. + --diff=program use diff program and options
  60. +
  61. + --compat-version=version provide compatibility with Perl version
  62. + --cplusplus accept C++ comments
  63. +
  64. + --quiet don't output anything except fatal errors
  65. + --nodiag don't show diagnostics
  66. + --nohints don't show hints
  67. + --nochanges don't suggest changes
  68. + --nofilter don't filter input files
  69. +
  70. + --strip strip all script and doc functionality from
  71. + ppport.h
  72. +
  73. + --list-provided list provided API
  74. + --list-unsupported list unsupported API
  75. + --api-info=name show Perl API portability information
  76. +
  77. +=head1 COMPATIBILITY
  78. +
  79. +This version of F<ppport.h> is designed to support operation with Perl
  80. +installations back to 5.003, and has been tested up to 5.11.5.
  81. +
  82. +=head1 OPTIONS
  83. +
  84. +=head2 --help
  85. +
  86. +Display a brief usage summary.
  87. +
  88. +=head2 --version
  89. +
  90. +Display the version of F<ppport.h>.
  91. +
  92. +=head2 --patch=I<file>
  93. +
  94. +If this option is given, a single patch file will be created if
  95. +any changes are suggested. This requires a working diff program
  96. +to be installed on your system.
  97. +
  98. +=head2 --copy=I<suffix>
  99. +
  100. +If this option is given, a copy of each file will be saved with
  101. +the given suffix that contains the suggested changes. This does
  102. +not require any external programs. Note that this does not
  103. +automagially add a dot between the original filename and the
  104. +suffix. If you want the dot, you have to include it in the option
  105. +argument.
  106. +
  107. +If neither C<--patch> or C<--copy> are given, the default is to
  108. +simply print the diffs for each file. This requires either
  109. +C<Text::Diff> or a C<diff> program to be installed.
  110. +
  111. +=head2 --diff=I<program>
  112. +
  113. +Manually set the diff program and options to use. The default
  114. +is to use C<Text::Diff>, when installed, and output unified
  115. +context diffs.
  116. +
  117. +=head2 --compat-version=I<version>
  118. +
  119. +Tell F<ppport.h> to check for compatibility with the given
  120. +Perl version. The default is to check for compatibility with Perl
  121. +version 5.003. You can use this option to reduce the output
  122. +of F<ppport.h> if you intend to be backward compatible only
  123. +down to a certain Perl version.
  124. +
  125. +=head2 --cplusplus
  126. +
  127. +Usually, F<ppport.h> will detect C++ style comments and
  128. +replace them with C style comments for portability reasons.
  129. +Using this option instructs F<ppport.h> to leave C++
  130. +comments untouched.
  131. +
  132. +=head2 --quiet
  133. +
  134. +Be quiet. Don't print anything except fatal errors.
  135. +
  136. +=head2 --nodiag
  137. +
  138. +Don't output any diagnostic messages. Only portability
  139. +alerts will be printed.
  140. +
  141. +=head2 --nohints
  142. +
  143. +Don't output any hints. Hints often contain useful portability
  144. +notes. Warnings will still be displayed.
  145. +
  146. +=head2 --nochanges
  147. +
  148. +Don't suggest any changes. Only give diagnostic output and hints
  149. +unless these are also deactivated.
  150. +
  151. +=head2 --nofilter
  152. +
  153. +Don't filter the list of input files. By default, files not looking
  154. +like source code (i.e. not *.xs, *.c, *.cc, *.cpp or *.h) are skipped.
  155. +
  156. +=head2 --strip
  157. +
  158. +Strip all script and documentation functionality from F<ppport.h>.
  159. +This reduces the size of F<ppport.h> dramatically and may be useful
  160. +if you want to include F<ppport.h> in smaller modules without
  161. +increasing their distribution size too much.
  162. +
  163. +The stripped F<ppport.h> will have a C<--unstrip> option that allows
  164. +you to undo the stripping, but only if an appropriate C<Devel::PPPort>
  165. +module is installed.
  166. +
  167. +=head2 --list-provided
  168. +
  169. +Lists the API elements for which compatibility is provided by
  170. +F<ppport.h>. Also lists if it must be explicitly requested,
  171. +if it has dependencies, and if there are hints or warnings for it.
  172. +
  173. +=head2 --list-unsupported
  174. +
  175. +Lists the API elements that are known not to be supported by
  176. +F<ppport.h> and below which version of Perl they probably
  177. +won't be available or work.
  178. +
  179. +=head2 --api-info=I<name>
  180. +
  181. +Show portability information for API elements matching I<name>.
  182. +If I<name> is surrounded by slashes, it is interpreted as a regular
  183. +expression.
  184. +
  185. +=head1 DESCRIPTION
  186. +
  187. +In order for a Perl extension (XS) module to be as portable as possible
  188. +across differing versions of Perl itself, certain steps need to be taken.
  189. +
  190. +=over 4
  191. +
  192. +=item *
  193. +
  194. +Including this header is the first major one. This alone will give you
  195. +access to a large part of the Perl API that hasn't been available in
  196. +earlier Perl releases. Use
  197. +
  198. + perl ppport.h --list-provided
  199. +
  200. +to see which API elements are provided by ppport.h.
  201. +
  202. +=item *
  203. +
  204. +You should avoid using deprecated parts of the API. For example, using
  205. +global Perl variables without the C<PL_> prefix is deprecated. Also,
  206. +some API functions used to have a C<perl_> prefix. Using this form is
  207. +also deprecated. You can safely use the supported API, as F<ppport.h>
  208. +will provide wrappers for older Perl versions.
  209. +
  210. +=item *
  211. +
  212. +If you use one of a few functions or variables that were not present in
  213. +earlier versions of Perl, and that can't be provided using a macro, you
  214. +have to explicitly request support for these functions by adding one or
  215. +more C<#define>s in your source code before the inclusion of F<ppport.h>.
  216. +
  217. +These functions or variables will be marked C<explicit> in the list shown
  218. +by C<--list-provided>.
  219. +
  220. +Depending on whether you module has a single or multiple files that
  221. +use such functions or variables, you want either C<static> or global
  222. +variants.
  223. +
  224. +For a C<static> function or variable (used only in a single source
  225. +file), use:
  226. +
  227. + #define NEED_function
  228. + #define NEED_variable
  229. +
  230. +For a global function or variable (used in multiple source files),
  231. +use:
  232. +
  233. + #define NEED_function_GLOBAL
  234. + #define NEED_variable_GLOBAL
  235. +
  236. +Note that you mustn't have more than one global request for the
  237. +same function or variable in your project.
  238. +
  239. + Function / Variable Static Request Global Request
  240. + -----------------------------------------------------------------------------------------
  241. + PL_parser NEED_PL_parser NEED_PL_parser_GLOBAL
  242. + PL_signals NEED_PL_signals NEED_PL_signals_GLOBAL
  243. + eval_pv() NEED_eval_pv NEED_eval_pv_GLOBAL
  244. + grok_bin() NEED_grok_bin NEED_grok_bin_GLOBAL
  245. + grok_hex() NEED_grok_hex NEED_grok_hex_GLOBAL
  246. + grok_number() NEED_grok_number NEED_grok_number_GLOBAL
  247. + grok_numeric_radix() NEED_grok_numeric_radix NEED_grok_numeric_radix_GLOBAL
  248. + grok_oct() NEED_grok_oct NEED_grok_oct_GLOBAL
  249. + load_module() NEED_load_module NEED_load_module_GLOBAL
  250. + my_snprintf() NEED_my_snprintf NEED_my_snprintf_GLOBAL
  251. + my_sprintf() NEED_my_sprintf NEED_my_sprintf_GLOBAL
  252. + my_strlcat() NEED_my_strlcat NEED_my_strlcat_GLOBAL
  253. + my_strlcpy() NEED_my_strlcpy NEED_my_strlcpy_GLOBAL
  254. + newCONSTSUB() NEED_newCONSTSUB NEED_newCONSTSUB_GLOBAL
  255. + newRV_noinc() NEED_newRV_noinc NEED_newRV_noinc_GLOBAL
  256. + newSV_type() NEED_newSV_type NEED_newSV_type_GLOBAL
  257. + newSVpvn_flags() NEED_newSVpvn_flags NEED_newSVpvn_flags_GLOBAL
  258. + newSVpvn_share() NEED_newSVpvn_share NEED_newSVpvn_share_GLOBAL
  259. + pv_display() NEED_pv_display NEED_pv_display_GLOBAL
  260. + pv_escape() NEED_pv_escape NEED_pv_escape_GLOBAL
  261. + pv_pretty() NEED_pv_pretty NEED_pv_pretty_GLOBAL
  262. + sv_2pv_flags() NEED_sv_2pv_flags NEED_sv_2pv_flags_GLOBAL
  263. + sv_2pvbyte() NEED_sv_2pvbyte NEED_sv_2pvbyte_GLOBAL
  264. + sv_catpvf_mg() NEED_sv_catpvf_mg NEED_sv_catpvf_mg_GLOBAL
  265. + sv_catpvf_mg_nocontext() NEED_sv_catpvf_mg_nocontext NEED_sv_catpvf_mg_nocontext_GLOBAL
  266. + sv_pvn_force_flags() NEED_sv_pvn_force_flags NEED_sv_pvn_force_flags_GLOBAL
  267. + sv_setpvf_mg() NEED_sv_setpvf_mg NEED_sv_setpvf_mg_GLOBAL
  268. + sv_setpvf_mg_nocontext() NEED_sv_setpvf_mg_nocontext NEED_sv_setpvf_mg_nocontext_GLOBAL
  269. + vload_module() NEED_vload_module NEED_vload_module_GLOBAL
  270. + vnewSVpvf() NEED_vnewSVpvf NEED_vnewSVpvf_GLOBAL
  271. + warner() NEED_warner NEED_warner_GLOBAL
  272. +
  273. +To avoid namespace conflicts, you can change the namespace of the
  274. +explicitly exported functions / variables using the C<DPPP_NAMESPACE>
  275. +macro. Just C<#define> the macro before including C<ppport.h>:
  276. +
  277. + #define DPPP_NAMESPACE MyOwnNamespace_
  278. + #include "ppport.h"
  279. +
  280. +The default namespace is C<DPPP_>.
  281. +
  282. +=back
  283. +
  284. +The good thing is that most of the above can be checked by running
  285. +F<ppport.h> on your source code. See the next section for
  286. +details.
  287. +
  288. +=head1 EXAMPLES
  289. +
  290. +To verify whether F<ppport.h> is needed for your module, whether you
  291. +should make any changes to your code, and whether any special defines
  292. +should be used, F<ppport.h> can be run as a Perl script to check your
  293. +source code. Simply say:
  294. +
  295. + perl ppport.h
  296. +
  297. +The result will usually be a list of patches suggesting changes
  298. +that should at least be acceptable, if not necessarily the most
  299. +efficient solution, or a fix for all possible problems.
  300. +
  301. +If you know that your XS module uses features only available in
  302. +newer Perl releases, if you're aware that it uses C++ comments,
  303. +and if you want all suggestions as a single patch file, you could
  304. +use something like this:
  305. +
  306. + perl ppport.h --compat-version=5.6.0 --cplusplus --patch=test.diff
  307. +
  308. +If you only want your code to be scanned without any suggestions
  309. +for changes, use:
  310. +
  311. + perl ppport.h --nochanges
  312. +
  313. +You can specify a different C<diff> program or options, using
  314. +the C<--diff> option:
  315. +
  316. + perl ppport.h --diff='diff -C 10'
  317. +
  318. +This would output context diffs with 10 lines of context.
  319. +
  320. +If you want to create patched copies of your files instead, use:
  321. +
  322. + perl ppport.h --copy=.new
  323. +
  324. +To display portability information for the C<newSVpvn> function,
  325. +use:
  326. +
  327. + perl ppport.h --api-info=newSVpvn
  328. +
  329. +Since the argument to C<--api-info> can be a regular expression,
  330. +you can use
  331. +
  332. + perl ppport.h --api-info=/_nomg$/
  333. +
  334. +to display portability information for all C<_nomg> functions or
  335. +
  336. + perl ppport.h --api-info=/./
  337. +
  338. +to display information for all known API elements.
  339. +
  340. +=head1 BUGS
  341. +
  342. +If this version of F<ppport.h> is causing failure during
  343. +the compilation of this module, please check if newer versions
  344. +of either this module or C<Devel::PPPort> are available on CPAN
  345. +before sending a bug report.
  346. +
  347. +If F<ppport.h> was generated using the latest version of
  348. +C<Devel::PPPort> and is causing failure of this module, please
  349. +file a bug report using the CPAN Request Tracker at L<http://rt.cpan.org/>.
  350. +
  351. +Please include the following information:
  352. +
  353. +=over 4
  354. +
  355. +=item 1.
  356. +
  357. +The complete output from running "perl -V"
  358. +
  359. +=item 2.
  360. +
  361. +This file.
  362. +
  363. +=item 3.
  364. +
  365. +The name and version of the module you were trying to build.
  366. +
  367. +=item 4.
  368. +
  369. +A full log of the build that failed.
  370. +
  371. +=item 5.
  372. +
  373. +Any other information that you think could be relevant.
  374. +
  375. +=back
  376. +
  377. +For the latest version of this code, please get the C<Devel::PPPort>
  378. +module from CPAN.
  379. +
  380. +=head1 COPYRIGHT
  381. +
  382. +Version 3.x, Copyright (c) 2004-2013, Marcus Holland-Moritz.
  383. +
  384. +Version 2.x, Copyright (C) 2001, Paul Marquess.
  385. +
  386. +Version 1.x, Copyright (C) 1999, Kenneth Albanowski.
  387. +
  388. +This program is free software; you can redistribute it and/or
  389. +modify it under the same terms as Perl itself.
  390. +
  391. +=head1 SEE ALSO
  392. +
  393. +See L<Devel::PPPort>.
  394. +
  395. +=cut
  396. +
  397. +use strict;
  398. +
  399. +# Disable broken TRIE-optimization
  400. +BEGIN { eval '${^RE_TRIE_MAXBUF} = -1' if $] >= 5.009004 && $] <= 5.009005 }
  401. +
  402. +my $VERSION = 3.21;
  403. +
  404. +my %opt = (
  405. + quiet => 0,
  406. + diag => 1,
  407. + hints => 1,
  408. + changes => 1,
  409. + cplusplus => 0,
  410. + filter => 1,
  411. + strip => 0,
  412. + version => 0,
  413. +);
  414. +
  415. +my($ppport) = $0 =~ /([\w.]+)$/;
  416. +my $LF = '(?:\r\n|[\r\n])'; # line feed
  417. +my $HS = "[ \t]"; # horizontal whitespace
  418. +
  419. +# Never use C comments in this file!
  420. +my $ccs = '/'.'*';
  421. +my $cce = '*'.'/';
  422. +my $rccs = quotemeta $ccs;
  423. +my $rcce = quotemeta $cce;
  424. +
  425. +eval {
  426. + require Getopt::Long;
  427. + Getopt::Long::GetOptions(\%opt, qw(
  428. + help quiet diag! filter! hints! changes! cplusplus strip version
  429. + patch=s copy=s diff=s compat-version=s
  430. + list-provided list-unsupported api-info=s
  431. + )) or usage();
  432. +};
  433. +
  434. +if ($@ and grep /^-/, @ARGV) {
  435. + usage() if "@ARGV" =~ /^--?h(?:elp)?$/;
  436. + die "Getopt::Long not found. Please don't use any options.\n";
  437. +}
  438. +
  439. +if ($opt{version}) {
  440. + print "This is $0 $VERSION.\n";
  441. + exit 0;
  442. +}
  443. +
  444. +usage() if $opt{help};
  445. +strip() if $opt{strip};
  446. +
  447. +if (exists $opt{'compat-version'}) {
  448. + my($r,$v,$s) = eval { parse_version($opt{'compat-version'}) };
  449. + if ($@) {
  450. + die "Invalid version number format: '$opt{'compat-version'}'\n";
  451. + }
  452. + die "Only Perl 5 is supported\n" if $r != 5;
  453. + die "Invalid version number: $opt{'compat-version'}\n" if $v >= 1000 || $s >= 1000;
  454. + $opt{'compat-version'} = sprintf "%d.%03d%03d", $r, $v, $s;
  455. +}
  456. +else {
  457. + $opt{'compat-version'} = 5;
  458. +}
  459. +
  460. +my %API = map { /^(\w+)\|([^|]*)\|([^|]*)\|(\w*)$/
  461. + ? ( $1 => {
  462. + ($2 ? ( base => $2 ) : ()),
  463. + ($3 ? ( todo => $3 ) : ()),
  464. + (index($4, 'v') >= 0 ? ( varargs => 1 ) : ()),
  465. + (index($4, 'p') >= 0 ? ( provided => 1 ) : ()),
  466. + (index($4, 'n') >= 0 ? ( nothxarg => 1 ) : ()),
  467. + } )
  468. + : die "invalid spec: $_" } qw(
  469. +AvFILLp|5.004050||p
  470. +AvFILL|||
  471. +BhkDISABLE||5.019003|
  472. +BhkENABLE||5.019003|
  473. +BhkENTRY_set||5.019003|
  474. +BhkENTRY|||
  475. +BhkFLAGS|||
  476. +CALL_BLOCK_HOOKS|||
  477. +CLASS|||n
  478. +CPERLscope|5.005000||p
  479. +CX_CURPAD_SAVE|||
  480. +CX_CURPAD_SV|||
  481. +CopFILEAV|5.006000||p
  482. +CopFILEGV_set|5.006000||p
  483. +CopFILEGV|5.006000||p
  484. +CopFILESV|5.006000||p
  485. +CopFILE_set|5.006000||p
  486. +CopFILE|5.006000||p
  487. +CopSTASHPV_set|5.006000||p
  488. +CopSTASHPV|5.006000||p
  489. +CopSTASH_eq|5.006000||p
  490. +CopSTASH_set|5.006000||p
  491. +CopSTASH|5.006000||p
  492. +CopyD|5.009002|5.004050|p
  493. +Copy||5.004050|
  494. +CvPADLIST||5.008001|
  495. +CvSTASH|||
  496. +CvWEAKOUTSIDE|||
  497. +DEFSV_set|5.010001||p
  498. +DEFSV|5.004050||p
  499. +END_EXTERN_C|5.005000||p
  500. +ENTER|||
  501. +ERRSV|5.004050||p
  502. +EXTEND|||
  503. +EXTERN_C|5.005000||p
  504. +F0convert|||n
  505. +FREETMPS|||
  506. +GIMME_V||5.004000|n
  507. +GIMME|||n
  508. +GROK_NUMERIC_RADIX|5.007002||p
  509. +G_ARRAY|||
  510. +G_DISCARD|||
  511. +G_EVAL|||
  512. +G_METHOD|5.006001||p
  513. +G_NOARGS|||
  514. +G_SCALAR|||
  515. +G_VOID||5.004000|
  516. +GetVars|||
  517. +GvAV|||
  518. +GvCV|||
  519. +GvHV|||
  520. +GvSVn|5.009003||p
  521. +GvSV|||
  522. +Gv_AMupdate||5.011000|
  523. +HEf_SVKEY||5.004000|
  524. +HeHASH||5.004000|
  525. +HeKEY||5.004000|
  526. +HeKLEN||5.004000|
  527. +HePV||5.004000|
  528. +HeSVKEY_force||5.004000|
  529. +HeSVKEY_set||5.004000|
  530. +HeSVKEY||5.004000|
  531. +HeUTF8||5.010001|
  532. +HeVAL||5.004000|
  533. +HvENAMELEN||5.015004|
  534. +HvENAMEUTF8||5.015004|
  535. +HvENAME||5.013007|
  536. +HvNAMELEN_get|5.009003||p
  537. +HvNAMELEN||5.015004|
  538. +HvNAMEUTF8||5.015004|
  539. +HvNAME_get|5.009003||p
  540. +HvNAME|||
  541. +INT2PTR|5.006000||p
  542. +IN_LOCALE_COMPILETIME|5.007002||p
  543. +IN_LOCALE_RUNTIME|5.007002||p
  544. +IN_LOCALE|5.007002||p
  545. +IN_PERL_COMPILETIME|5.008001||p
  546. +IS_NUMBER_GREATER_THAN_UV_MAX|5.007002||p
  547. +IS_NUMBER_INFINITY|5.007002||p
  548. +IS_NUMBER_IN_UV|5.007002||p
  549. +IS_NUMBER_NAN|5.007003||p
  550. +IS_NUMBER_NEG|5.007002||p
  551. +IS_NUMBER_NOT_INT|5.007002||p
  552. +IVSIZE|5.006000||p
  553. +IVTYPE|5.006000||p
  554. +IVdf|5.006000||p
  555. +LEAVE|||
  556. +LINKLIST||5.013006|
  557. +LVRET|||
  558. +MARK|||
  559. +MULTICALL||5.019003|
  560. +MY_CXT_CLONE|5.009002||p
  561. +MY_CXT_INIT|5.007003||p
  562. +MY_CXT|5.007003||p
  563. +MoveD|5.009002|5.004050|p
  564. +Move||5.004050|
  565. +NOOP|5.005000||p
  566. +NUM2PTR|5.006000||p
  567. +NVTYPE|5.006000||p
  568. +NVef|5.006001||p
  569. +NVff|5.006001||p
  570. +NVgf|5.006001||p
  571. +Newxc|5.009003||p
  572. +Newxz|5.009003||p
  573. +Newx|5.009003||p
  574. +Nullav|||
  575. +Nullch|||
  576. +Nullcv|||
  577. +Nullhv|||
  578. +Nullsv|||
  579. +OP_CLASS||5.013007|
  580. +OP_DESC||5.007003|
  581. +OP_NAME||5.007003|
  582. +ORIGMARK|||
  583. +PAD_BASE_SV|||
  584. +PAD_CLONE_VARS|||
  585. +PAD_COMPNAME_FLAGS|||
  586. +PAD_COMPNAME_GEN_set|||
  587. +PAD_COMPNAME_GEN|||
  588. +PAD_COMPNAME_OURSTASH|||
  589. +PAD_COMPNAME_PV|||
  590. +PAD_COMPNAME_TYPE|||
  591. +PAD_RESTORE_LOCAL|||
  592. +PAD_SAVE_LOCAL|||
  593. +PAD_SAVE_SETNULLPAD|||
  594. +PAD_SETSV|||
  595. +PAD_SET_CUR_NOSAVE|||
  596. +PAD_SET_CUR|||
  597. +PAD_SVl|||
  598. +PAD_SV|||
  599. +PERLIO_FUNCS_CAST|5.009003||p
  600. +PERLIO_FUNCS_DECL|5.009003||p
  601. +PERL_ABS|5.008001||p
  602. +PERL_BCDVERSION|5.019002||p
  603. +PERL_GCC_BRACE_GROUPS_FORBIDDEN|5.008001||p
  604. +PERL_HASH|5.004000||p
  605. +PERL_INT_MAX|5.004000||p
  606. +PERL_INT_MIN|5.004000||p
  607. +PERL_LONG_MAX|5.004000||p
  608. +PERL_LONG_MIN|5.004000||p
  609. +PERL_MAGIC_arylen|5.007002||p
  610. +PERL_MAGIC_backref|5.007002||p
  611. +PERL_MAGIC_bm|5.007002||p
  612. +PERL_MAGIC_collxfrm|5.007002||p
  613. +PERL_MAGIC_dbfile|5.007002||p
  614. +PERL_MAGIC_dbline|5.007002||p
  615. +PERL_MAGIC_defelem|5.007002||p
  616. +PERL_MAGIC_envelem|5.007002||p
  617. +PERL_MAGIC_env|5.007002||p
  618. +PERL_MAGIC_ext|5.007002||p
  619. +PERL_MAGIC_fm|5.007002||p
  620. +PERL_MAGIC_glob|5.019002||p
  621. +PERL_MAGIC_isaelem|5.007002||p
  622. +PERL_MAGIC_isa|5.007002||p
  623. +PERL_MAGIC_mutex|5.019002||p
  624. +PERL_MAGIC_nkeys|5.007002||p
  625. +PERL_MAGIC_overload_elem|5.019002||p
  626. +PERL_MAGIC_overload_table|5.007002||p
  627. +PERL_MAGIC_overload|5.019002||p
  628. +PERL_MAGIC_pos|5.007002||p
  629. +PERL_MAGIC_qr|5.007002||p
  630. +PERL_MAGIC_regdata|5.007002||p
  631. +PERL_MAGIC_regdatum|5.007002||p
  632. +PERL_MAGIC_regex_global|5.007002||p
  633. +PERL_MAGIC_shared_scalar|5.007003||p
  634. +PERL_MAGIC_shared|5.007003||p
  635. +PERL_MAGIC_sigelem|5.007002||p
  636. +PERL_MAGIC_sig|5.007002||p
  637. +PERL_MAGIC_substr|5.007002||p
  638. +PERL_MAGIC_sv|5.007002||p
  639. +PERL_MAGIC_taint|5.007002||p
  640. +PERL_MAGIC_tiedelem|5.007002||p
  641. +PERL_MAGIC_tiedscalar|5.007002||p
  642. +PERL_MAGIC_tied|5.007002||p
  643. +PERL_MAGIC_utf8|5.008001||p
  644. +PERL_MAGIC_uvar_elem|5.007003||p
  645. +PERL_MAGIC_uvar|5.007002||p
  646. +PERL_MAGIC_vec|5.007002||p
  647. +PERL_MAGIC_vstring|5.008001||p
  648. +PERL_PV_ESCAPE_ALL|5.009004||p
  649. +PERL_PV_ESCAPE_FIRSTCHAR|5.009004||p
  650. +PERL_PV_ESCAPE_NOBACKSLASH|5.009004||p
  651. +PERL_PV_ESCAPE_NOCLEAR|5.009004||p
  652. +PERL_PV_ESCAPE_QUOTE|5.009004||p
  653. +PERL_PV_ESCAPE_RE|5.009005||p
  654. +PERL_PV_ESCAPE_UNI_DETECT|5.009004||p
  655. +PERL_PV_ESCAPE_UNI|5.009004||p
  656. +PERL_PV_PRETTY_DUMP|5.009004||p
  657. +PERL_PV_PRETTY_ELLIPSES|5.010000||p
  658. +PERL_PV_PRETTY_LTGT|5.009004||p
  659. +PERL_PV_PRETTY_NOCLEAR|5.010000||p
  660. +PERL_PV_PRETTY_QUOTE|5.009004||p
  661. +PERL_PV_PRETTY_REGPROP|5.009004||p
  662. +PERL_QUAD_MAX|5.004000||p
  663. +PERL_QUAD_MIN|5.004000||p
  664. +PERL_REVISION|5.006000||p
  665. +PERL_SCAN_ALLOW_UNDERSCORES|5.007003||p
  666. +PERL_SCAN_DISALLOW_PREFIX|5.007003||p
  667. +PERL_SCAN_GREATER_THAN_UV_MAX|5.007003||p
  668. +PERL_SCAN_SILENT_ILLDIGIT|5.008001||p
  669. +PERL_SHORT_MAX|5.004000||p
  670. +PERL_SHORT_MIN|5.004000||p
  671. +PERL_SIGNALS_UNSAFE_FLAG|5.008001||p
  672. +PERL_SUBVERSION|5.006000||p
  673. +PERL_SYS_INIT3||5.010000|
  674. +PERL_SYS_INIT||5.010000|
  675. +PERL_SYS_TERM||5.019003|
  676. +PERL_UCHAR_MAX|5.004000||p
  677. +PERL_UCHAR_MIN|5.004000||p
  678. +PERL_UINT_MAX|5.004000||p
  679. +PERL_UINT_MIN|5.004000||p
  680. +PERL_ULONG_MAX|5.004000||p
  681. +PERL_ULONG_MIN|5.004000||p
  682. +PERL_UNUSED_ARG|5.009003||p
  683. +PERL_UNUSED_CONTEXT|5.009004||p
  684. +PERL_UNUSED_DECL|5.007002||p
  685. +PERL_UNUSED_VAR|5.007002||p
  686. +PERL_UQUAD_MAX|5.004000||p
  687. +PERL_UQUAD_MIN|5.004000||p
  688. +PERL_USE_GCC_BRACE_GROUPS|5.009004||p
  689. +PERL_USHORT_MAX|5.004000||p
  690. +PERL_USHORT_MIN|5.004000||p
  691. +PERL_VERSION|5.006000||p
  692. +PL_DBsignal|5.005000||p
  693. +PL_DBsingle|||pn
  694. +PL_DBsub|||pn
  695. +PL_DBtrace|||pn
  696. +PL_Sv|5.005000||p
  697. +PL_bufend|5.019002||p
  698. +PL_bufptr|5.019002||p
  699. +PL_check||5.006000|
  700. +PL_compiling|5.004050||p
  701. +PL_comppad_name||5.017004|
  702. +PL_comppad||5.008001|
  703. +PL_copline|5.019002||p
  704. +PL_curcop|5.004050||p
  705. +PL_curpad||5.005000|
  706. +PL_curstash|5.004050||p
  707. +PL_debstash|5.004050||p
  708. +PL_defgv|5.004050||p
  709. +PL_diehook|5.004050||p
  710. +PL_dirty|5.004050||p
  711. +PL_dowarn|||pn
  712. +PL_errgv|5.004050||p
  713. +PL_error_count|5.019002||p
  714. +PL_expect|5.019002||p
  715. +PL_hexdigit|5.005000||p
  716. +PL_hints|5.005000||p
  717. +PL_in_my_stash|5.019002||p
  718. +PL_in_my|5.019002||p
  719. +PL_keyword_plugin||5.011002|
  720. +PL_last_in_gv|||n
  721. +PL_laststatval|5.005000||p
  722. +PL_lex_state|5.019002||p
  723. +PL_lex_stuff|5.019002||p
  724. +PL_linestr|5.019002||p
  725. +PL_modglobal||5.005000|n
  726. +PL_na|5.004050||pn
  727. +PL_no_modify|5.006000||p
  728. +PL_ofsgv|||n
  729. +PL_opfreehook||5.011000|n
  730. +PL_parser|5.009005|5.009005|p
  731. +PL_peepp||5.007003|n
  732. +PL_perl_destruct_level|5.004050||p
  733. +PL_perldb|5.004050||p
  734. +PL_ppaddr|5.006000||p
  735. +PL_rpeepp||5.013005|n
  736. +PL_rsfp_filters|5.019002||p
  737. +PL_rsfp|5.019002||p
  738. +PL_rs|||n
  739. +PL_signals|5.008001||p
  740. +PL_stack_base|5.004050||p
  741. +PL_stack_sp|5.004050||p
  742. +PL_statcache|5.005000||p
  743. +PL_stdingv|5.004050||p
  744. +PL_sv_arenaroot|5.004050||p
  745. +PL_sv_no|5.004050||pn
  746. +PL_sv_undef|5.004050||pn
  747. +PL_sv_yes|5.004050||pn
  748. +PL_tainted|5.004050||p
  749. +PL_tainting|5.004050||p
  750. +PL_tokenbuf|5.019002||p
  751. +POP_MULTICALL||5.019003|
  752. +POPi|||n
  753. +POPl|||n
  754. +POPn|||n
  755. +POPpbytex||5.007001|n
  756. +POPpx||5.005030|n
  757. +POPp|||n
  758. +POPs|||n
  759. +PTR2IV|5.006000||p
  760. +PTR2NV|5.006000||p
  761. +PTR2UV|5.006000||p
  762. +PTR2nat|5.009003||p
  763. +PTR2ul|5.007001||p
  764. +PTRV|5.006000||p
  765. +PUSHMARK|||
  766. +PUSH_MULTICALL||5.019003|
  767. +PUSHi|||
  768. +PUSHmortal|5.009002||p
  769. +PUSHn|||
  770. +PUSHp|||
  771. +PUSHs|||
  772. +PUSHu|5.004000||p
  773. +PUTBACK|||
  774. +PadARRAY||5.019003|
  775. +PadMAX||5.019003|
  776. +PadlistARRAY||5.019003|
  777. +PadlistMAX||5.019003|
  778. +PadlistNAMESARRAY||5.019003|
  779. +PadlistNAMESMAX||5.019003|
  780. +PadlistNAMES||5.019003|
  781. +PadlistREFCNT||5.017004|
  782. +PadnameIsOUR|||
  783. +PadnameIsSTATE|||
  784. +PadnameLEN||5.019003|
  785. +PadnameOURSTASH|||
  786. +PadnameOUTER|||
  787. +PadnamePV||5.019003|
  788. +PadnameSV||5.019003|
  789. +PadnameTYPE|||
  790. +PadnameUTF8||5.019003|
  791. +PadnamelistARRAY||5.019003|
  792. +PadnamelistMAX||5.019003|
  793. +PerlIO_clearerr||5.007003|
  794. +PerlIO_close||5.007003|
  795. +PerlIO_context_layers||5.009004|
  796. +PerlIO_eof||5.007003|
  797. +PerlIO_error||5.007003|
  798. +PerlIO_fileno||5.007003|
  799. +PerlIO_fill||5.007003|
  800. +PerlIO_flush||5.007003|
  801. +PerlIO_get_base||5.007003|
  802. +PerlIO_get_bufsiz||5.007003|
  803. +PerlIO_get_cnt||5.007003|
  804. +PerlIO_get_ptr||5.007003|
  805. +PerlIO_read||5.007003|
  806. +PerlIO_seek||5.007003|
  807. +PerlIO_set_cnt||5.007003|
  808. +PerlIO_set_ptrcnt||5.007003|
  809. +PerlIO_setlinebuf||5.007003|
  810. +PerlIO_stderr||5.007003|
  811. +PerlIO_stdin||5.007003|
  812. +PerlIO_stdout||5.007003|
  813. +PerlIO_tell||5.007003|
  814. +PerlIO_unread||5.007003|
  815. +PerlIO_write||5.007003|
  816. +Perl_signbit||5.009005|n
  817. +PoisonFree|5.009004||p
  818. +PoisonNew|5.009004||p
  819. +PoisonWith|5.009004||p
  820. +Poison|5.008000||p
  821. +READ_XDIGIT||5.017006|
  822. +RETVAL|||n
  823. +Renewc|||
  824. +Renew|||
  825. +SAVECLEARSV|||
  826. +SAVECOMPPAD|||
  827. +SAVEPADSV|||
  828. +SAVETMPS|||
  829. +SAVE_DEFSV|5.004050||p
  830. +SPAGAIN|||
  831. +SP|||
  832. +START_EXTERN_C|5.005000||p
  833. +START_MY_CXT|5.007003||p
  834. +STMT_END|||p
  835. +STMT_START|||p
  836. +STR_WITH_LEN|5.009003||p
  837. +ST|||
  838. +SV_CONST_RETURN|5.009003||p
  839. +SV_COW_DROP_PV|5.008001||p
  840. +SV_COW_SHARED_HASH_KEYS|5.009005||p
  841. +SV_GMAGIC|5.007002||p
  842. +SV_HAS_TRAILING_NUL|5.009004||p
  843. +SV_IMMEDIATE_UNREF|5.007001||p
  844. +SV_MUTABLE_RETURN|5.009003||p
  845. +SV_NOSTEAL|5.009002||p
  846. +SV_SMAGIC|5.009003||p
  847. +SV_UTF8_NO_ENCODING|5.008001||p
  848. +SVfARG|5.009005||p
  849. +SVf_UTF8|5.006000||p
  850. +SVf|5.006000||p
  851. +SVt_INVLIST||5.019002|
  852. +SVt_IV|||
  853. +SVt_NULL|||
  854. +SVt_NV|||
  855. +SVt_PVAV|||
  856. +SVt_PVCV|||
  857. +SVt_PVFM|||
  858. +SVt_PVGV|||
  859. +SVt_PVHV|||
  860. +SVt_PVIO|||
  861. +SVt_PVIV|||
  862. +SVt_PVLV|||
  863. +SVt_PVMG|||
  864. +SVt_PVNV|||
  865. +SVt_PV|||
  866. +SVt_REGEXP||5.011000|
  867. +Safefree|||
  868. +Slab_Alloc|||
  869. +Slab_Free|||
  870. +Slab_to_ro|||
  871. +Slab_to_rw|||
  872. +StructCopy|||
  873. +SvCUR_set|||
  874. +SvCUR|||
  875. +SvEND|||
  876. +SvGAMAGIC||5.006001|
  877. +SvGETMAGIC|5.004050||p
  878. +SvGROW|||
  879. +SvIOK_UV||5.006000|
  880. +SvIOK_notUV||5.006000|
  881. +SvIOK_off|||
  882. +SvIOK_only_UV||5.006000|
  883. +SvIOK_only|||
  884. +SvIOK_on|||
  885. +SvIOKp|||
  886. +SvIOK|||
  887. +SvIVX|||
  888. +SvIV_nomg|5.009001||p
  889. +SvIV_set|||
  890. +SvIVx|||
  891. +SvIV|||
  892. +SvIsCOW_shared_hash||5.008003|
  893. +SvIsCOW||5.008003|
  894. +SvLEN_set|||
  895. +SvLEN|||
  896. +SvLOCK||5.007003|
  897. +SvMAGIC_set|5.009003||p
  898. +SvNIOK_off|||
  899. +SvNIOKp|||
  900. +SvNIOK|||
  901. +SvNOK_off|||
  902. +SvNOK_only|||
  903. +SvNOK_on|||
  904. +SvNOKp|||
  905. +SvNOK|||
  906. +SvNVX|||
  907. +SvNV_nomg||5.013002|
  908. +SvNV_set|||
  909. +SvNVx|||
  910. +SvNV|||
  911. +SvOK|||
  912. +SvOOK_offset||5.011000|
  913. +SvOOK|||
  914. +SvPOK_off|||
  915. +SvPOK_only_UTF8||5.006000|
  916. +SvPOK_only|||
  917. +SvPOK_on|||
  918. +SvPOKp|||
  919. +SvPOK|||
  920. +SvPVX_const|5.009003||p
  921. +SvPVX_mutable|5.009003||p
  922. +SvPVX|||
  923. +SvPV_const|5.009003||p
  924. +SvPV_flags_const_nolen|5.009003||p
  925. +SvPV_flags_const|5.009003||p
  926. +SvPV_flags_mutable|5.009003||p
  927. +SvPV_flags|5.007002||p
  928. +SvPV_force_flags_mutable|5.009003||p
  929. +SvPV_force_flags_nolen|5.009003||p
  930. +SvPV_force_flags|5.007002||p
  931. +SvPV_force_mutable|5.009003||p
  932. +SvPV_force_nolen|5.009003||p
  933. +SvPV_force_nomg_nolen|5.009003||p
  934. +SvPV_force_nomg|5.007002||p
  935. +SvPV_force|||p
  936. +SvPV_mutable|5.009003||p
  937. +SvPV_nolen_const|5.009003||p
  938. +SvPV_nolen|5.006000||p
  939. +SvPV_nomg_const_nolen|5.009003||p
  940. +SvPV_nomg_const|5.009003||p
  941. +SvPV_nomg_nolen|5.013007||p
  942. +SvPV_nomg|5.007002||p
  943. +SvPV_renew|5.009003||p
  944. +SvPV_set|||
  945. +SvPVbyte_force||5.009002|
  946. +SvPVbyte_nolen||5.006000|
  947. +SvPVbytex_force||5.006000|
  948. +SvPVbytex||5.006000|
  949. +SvPVbyte|5.006000||p
  950. +SvPVutf8_force||5.006000|
  951. +SvPVutf8_nolen||5.006000|
  952. +SvPVutf8x_force||5.006000|
  953. +SvPVutf8x||5.006000|
  954. +SvPVutf8||5.006000|
  955. +SvPVx|||
  956. +SvPV|||
  957. +SvREFCNT_dec_NN||5.017007|
  958. +SvREFCNT_dec|||
  959. +SvREFCNT_inc_NN|5.009004||p
  960. +SvREFCNT_inc_simple_NN|5.009004||p
  961. +SvREFCNT_inc_simple_void_NN|5.009004||p
  962. +SvREFCNT_inc_simple_void|5.009004||p
  963. +SvREFCNT_inc_simple|5.009004||p
  964. +SvREFCNT_inc_void_NN|5.009004||p
  965. +SvREFCNT_inc_void|5.009004||p
  966. +SvREFCNT_inc|||p
  967. +SvREFCNT|||
  968. +SvROK_off|||
  969. +SvROK_on|||
  970. +SvROK|||
  971. +SvRV_set|5.009003||p
  972. +SvRV|||
  973. +SvRXOK||5.009005|
  974. +SvRX||5.009005|
  975. +SvSETMAGIC|||
  976. +SvSHARED_HASH|5.009003||p
  977. +SvSHARE||5.007003|
  978. +SvSTASH_set|5.009003||p
  979. +SvSTASH|||
  980. +SvSetMagicSV_nosteal||5.004000|
  981. +SvSetMagicSV||5.004000|
  982. +SvSetSV_nosteal||5.004000|
  983. +SvSetSV|||
  984. +SvTAINTED_off||5.004000|
  985. +SvTAINTED_on||5.004000|
  986. +SvTAINTED||5.004000|
  987. +SvTAINT|||
  988. +SvTHINKFIRST|||
  989. +SvTRUE_nomg||5.013006|
  990. +SvTRUE|||
  991. +SvTYPE|||
  992. +SvUNLOCK||5.007003|
  993. +SvUOK|5.007001|5.006000|p
  994. +SvUPGRADE|||
  995. +SvUTF8_off||5.006000|
  996. +SvUTF8_on||5.006000|
  997. +SvUTF8||5.006000|
  998. +SvUVXx|5.004000||p
  999. +SvUVX|5.004000||p
  1000. +SvUV_nomg|5.009001||p
  1001. +SvUV_set|5.009003||p
  1002. +SvUVx|5.004000||p
  1003. +SvUV|5.004000||p
  1004. +SvVOK||5.008001|
  1005. +SvVSTRING_mg|5.009004||p
  1006. +THIS|||n
  1007. +UNDERBAR|5.009002||p
  1008. +UTF8_MAXBYTES|5.009002||p
  1009. +UVSIZE|5.006000||p
  1010. +UVTYPE|5.006000||p
  1011. +UVXf|5.007001||p
  1012. +UVof|5.006000||p
  1013. +UVuf|5.006000||p
  1014. +UVxf|5.006000||p
  1015. +WARN_ALL|5.006000||p
  1016. +WARN_AMBIGUOUS|5.006000||p
  1017. +WARN_ASSERTIONS|5.019002||p
  1018. +WARN_BAREWORD|5.006000||p
  1019. +WARN_CLOSED|5.006000||p
  1020. +WARN_CLOSURE|5.006000||p
  1021. +WARN_DEBUGGING|5.006000||p
  1022. +WARN_DEPRECATED|5.006000||p
  1023. +WARN_DIGIT|5.006000||p
  1024. +WARN_EXEC|5.006000||p
  1025. +WARN_EXITING|5.006000||p
  1026. +WARN_GLOB|5.006000||p
  1027. +WARN_INPLACE|5.006000||p
  1028. +WARN_INTERNAL|5.006000||p
  1029. +WARN_IO|5.006000||p
  1030. +WARN_LAYER|5.008000||p
  1031. +WARN_MALLOC|5.006000||p
  1032. +WARN_MISC|5.006000||p
  1033. +WARN_NEWLINE|5.006000||p
  1034. +WARN_NUMERIC|5.006000||p
  1035. +WARN_ONCE|5.006000||p
  1036. +WARN_OVERFLOW|5.006000||p
  1037. +WARN_PACK|5.006000||p
  1038. +WARN_PARENTHESIS|5.006000||p
  1039. +WARN_PIPE|5.006000||p
  1040. +WARN_PORTABLE|5.006000||p
  1041. +WARN_PRECEDENCE|5.006000||p
  1042. +WARN_PRINTF|5.006000||p
  1043. +WARN_PROTOTYPE|5.006000||p
  1044. +WARN_QW|5.006000||p
  1045. +WARN_RECURSION|5.006000||p
  1046. +WARN_REDEFINE|5.006000||p
  1047. +WARN_REGEXP|5.006000||p
  1048. +WARN_RESERVED|5.006000||p
  1049. +WARN_SEMICOLON|5.006000||p
  1050. +WARN_SEVERE|5.006000||p
  1051. +WARN_SIGNAL|5.006000||p
  1052. +WARN_SUBSTR|5.006000||p
  1053. +WARN_SYNTAX|5.006000||p
  1054. +WARN_TAINT|5.006000||p
  1055. +WARN_THREADS|5.008000||p
  1056. +WARN_UNINITIALIZED|5.006000||p
  1057. +WARN_UNOPENED|5.006000||p
  1058. +WARN_UNPACK|5.006000||p
  1059. +WARN_UNTIE|5.006000||p
  1060. +WARN_UTF8|5.006000||p
  1061. +WARN_VOID|5.006000||p
  1062. +WIDEST_UTYPE|5.015004||p
  1063. +XCPT_CATCH|5.009002||p
  1064. +XCPT_RETHROW|5.009002|5.007001|p
  1065. +XCPT_TRY_END|5.009002|5.004000|p
  1066. +XCPT_TRY_START|5.009002|5.004000|p
  1067. +XPUSHi|||
  1068. +XPUSHmortal|5.009002||p
  1069. +XPUSHn|||
  1070. +XPUSHp|||
  1071. +XPUSHs|||
  1072. +XPUSHu|5.004000||p
  1073. +XSPROTO|5.010000||p
  1074. +XSRETURN_EMPTY|||
  1075. +XSRETURN_IV|||
  1076. +XSRETURN_NO|||
  1077. +XSRETURN_NV|||
  1078. +XSRETURN_PV|||
  1079. +XSRETURN_UNDEF|||
  1080. +XSRETURN_UV|5.008001||p
  1081. +XSRETURN_YES|||
  1082. +XSRETURN|||p
  1083. +XST_mIV|||
  1084. +XST_mNO|||
  1085. +XST_mNV|||
  1086. +XST_mPV|||
  1087. +XST_mUNDEF|||
  1088. +XST_mUV|5.008001||p
  1089. +XST_mYES|||
  1090. +XS_APIVERSION_BOOTCHECK||5.013004|
  1091. +XS_EXTERNAL||5.019003|
  1092. +XS_INTERNAL||5.019003|
  1093. +XS_VERSION_BOOTCHECK|||
  1094. +XS_VERSION|||
  1095. +XSprePUSH|5.006000||p
  1096. +XS|||
  1097. +XopDISABLE||5.019003|
  1098. +XopENABLE||5.019003|
  1099. +XopENTRY_set||5.019003|
  1100. +XopENTRY||5.019003|
  1101. +XopFLAGS||5.013007|
  1102. +ZeroD|5.009002||p
  1103. +Zero|||
  1104. +_aMY_CXT|5.007003||p
  1105. +_add_range_to_invlist|||
  1106. +_append_range_to_invlist|||
  1107. +_core_swash_init|||
  1108. +_get_swash_invlist|||
  1109. +_invlist_array_init|||
  1110. +_invlist_contains_cp|||
  1111. +_invlist_contents|||
  1112. +_invlist_dump|||
  1113. +_invlist_intersection_maybe_complement_2nd|||
  1114. +_invlist_intersection|||
  1115. +_invlist_invert_prop|||
  1116. +_invlist_invert|||
  1117. +_invlist_len|||
  1118. +_invlist_populate_swatch|||
  1119. +_invlist_search|||
  1120. +_invlist_subtract|||
  1121. +_invlist_union_maybe_complement_2nd|||
  1122. +_invlist_union|||
  1123. +_is_uni_FOO||5.017008|
  1124. +_is_uni_perl_idcont||5.017008|
  1125. +_is_uni_perl_idstart||5.017007|
  1126. +_is_utf8_FOO||5.017008|
  1127. +_is_utf8_mark||5.017008|
  1128. +_is_utf8_perl_idcont||5.017008|
  1129. +_is_utf8_perl_idstart||5.017007|
  1130. +_new_invlist_C_array|||
  1131. +_new_invlist|||
  1132. +_pMY_CXT|5.007003||p
  1133. +_swash_inversion_hash|||
  1134. +_swash_to_invlist|||
  1135. +_to_fold_latin1|||
  1136. +_to_uni_fold_flags||5.013011|
  1137. +_to_upper_title_latin1|||
  1138. +_to_utf8_fold_flags||5.015006|
  1139. +_to_utf8_lower_flags||5.015006|
  1140. +_to_utf8_title_flags||5.015006|
  1141. +_to_utf8_upper_flags||5.015006|
  1142. +aMY_CXT_|5.007003||p
  1143. +aMY_CXT|5.007003||p
  1144. +aTHXR_|5.019002||p
  1145. +aTHXR|5.019002||p
  1146. +aTHX_|5.006000||p
  1147. +aTHX|5.006000||p
  1148. +aassign_common_vars|||
  1149. +add_cp_to_invlist|||
  1150. +add_data|||n
  1151. +add_utf16_textfilter|||
  1152. +addmad|||
  1153. +adjust_size_and_find_bucket|||n
  1154. +adjust_stack_on_leave|||
  1155. +alloc_maybe_populate_EXACT|||
  1156. +alloccopstash|||
  1157. +allocmy|||
  1158. +amagic_call|||
  1159. +amagic_cmp_locale|||
  1160. +amagic_cmp|||
  1161. +amagic_deref_call||5.013007|
  1162. +amagic_i_ncmp|||
  1163. +amagic_is_enabled|||
  1164. +amagic_ncmp|||
  1165. +anonymise_cv_maybe|||
  1166. +any_dup|||
  1167. +ao|||
  1168. +append_madprops|||
  1169. +apply_attrs_my|||
  1170. +apply_attrs_string||5.006001|
  1171. +apply_attrs|||
  1172. +apply|||
  1173. +assert_uft8_cache_coherent|||
  1174. +atfork_lock||5.007003|n
  1175. +atfork_unlock||5.007003|n
  1176. +av_arylen_p||5.009003|
  1177. +av_clear|||
  1178. +av_create_and_push||5.009005|
  1179. +av_create_and_unshift_one||5.009005|
  1180. +av_delete||5.006000|
  1181. +av_exists||5.006000|
  1182. +av_extend_guts|||
  1183. +av_extend|||
  1184. +av_fetch|||
  1185. +av_fill|||
  1186. +av_iter_p||5.011000|
  1187. +av_len|||
  1188. +av_make|||
  1189. +av_pop|||
  1190. +av_push|||
  1191. +av_reify|||
  1192. +av_shift|||
  1193. +av_store|||
  1194. +av_tindex||5.017009|
  1195. +av_top_index||5.017009|
  1196. +av_undef|||
  1197. +av_unshift|||
  1198. +ax|||n
  1199. +bad_type_gv|||
  1200. +bad_type_pv|||
  1201. +bind_match|||
  1202. +block_end|||
  1203. +block_gimme||5.004000|
  1204. +block_start|||
  1205. +blockhook_register||5.013003|
  1206. +boolSV|5.004000||p
  1207. +boot_core_PerlIO|||
  1208. +boot_core_UNIVERSAL|||
  1209. +boot_core_mro|||
  1210. +bytes_cmp_utf8||5.013007|
  1211. +bytes_from_utf8||5.007001|
  1212. +bytes_to_uni|||n
  1213. +bytes_to_utf8||5.006001|
  1214. +call_argv|5.006000||p
  1215. +call_atexit||5.006000|
  1216. +call_list||5.004000|
  1217. +call_method|5.006000||p
  1218. +call_pv|5.006000||p
  1219. +call_sv|5.006000||p
  1220. +caller_cx||5.013005|
  1221. +calloc||5.007002|n
  1222. +cando|||
  1223. +cast_i32||5.006000|
  1224. +cast_iv||5.006000|
  1225. +cast_ulong||5.006000|
  1226. +cast_uv||5.006000|
  1227. +check_locale_boundary_crossing|||
  1228. +check_type_and_open|||
  1229. +check_uni|||
  1230. +check_utf8_print|||
  1231. +checkcomma|||
  1232. +ckWARN|5.006000||p
  1233. +ck_entersub_args_core|||
  1234. +ck_entersub_args_list||5.013006|
  1235. +ck_entersub_args_proto_or_list||5.013006|
  1236. +ck_entersub_args_proto||5.013006|
  1237. +ck_warner_d||5.011001|v
  1238. +ck_warner||5.011001|v
  1239. +ckwarn_common|||
  1240. +ckwarn_d||5.009003|
  1241. +ckwarn||5.009003|
  1242. +cl_and|||n
  1243. +cl_anything|||n
  1244. +cl_init|||n
  1245. +cl_is_anything|||n
  1246. +cl_or|||n
  1247. +clear_placeholders|||
  1248. +clone_params_del|||n
  1249. +clone_params_new|||n
  1250. +closest_cop|||
  1251. +compute_EXACTish|||
  1252. +convert|||
  1253. +cop_fetch_label||5.015001|
  1254. +cop_free|||
  1255. +cop_hints_2hv||5.013007|
  1256. +cop_hints_fetch_pvn||5.013007|
  1257. +cop_hints_fetch_pvs||5.013007|
  1258. +cop_hints_fetch_pv||5.013007|
  1259. +cop_hints_fetch_sv||5.013007|
  1260. +cop_store_label||5.015001|
  1261. +cophh_2hv||5.013007|
  1262. +cophh_copy||5.013007|
  1263. +cophh_delete_pvn||5.013007|
  1264. +cophh_delete_pvs||5.013007|
  1265. +cophh_delete_pv||5.013007|
  1266. +cophh_delete_sv||5.013007|
  1267. +cophh_fetch_pvn||5.013007|
  1268. +cophh_fetch_pvs||5.013007|
  1269. +cophh_fetch_pv||5.013007|
  1270. +cophh_fetch_sv||5.013007|
  1271. +cophh_free||5.013007|
  1272. +cophh_new_empty||5.019003|
  1273. +cophh_store_pvn||5.013007|
  1274. +cophh_store_pvs||5.013007|
  1275. +cophh_store_pv||5.013007|
  1276. +cophh_store_sv||5.013007|
  1277. +core_prototype|||
  1278. +core_regclass_swash|||
  1279. +coresub_op|||
  1280. +could_it_be_a_POSIX_class|||
  1281. +cr_textfilter|||
  1282. +create_eval_scope|||
  1283. +croak_memory_wrap||5.019003|n
  1284. +croak_no_mem|||n
  1285. +croak_no_modify||5.013003|n
  1286. +croak_nocontext|||vn
  1287. +croak_popstack|||n
  1288. +croak_sv||5.013001|
  1289. +croak_xs_usage||5.010001|n
  1290. +croak|||v
  1291. +csighandler||5.009003|n
  1292. +curmad|||
  1293. +current_re_engine|||
  1294. +curse|||
  1295. +custom_op_desc||5.007003|
  1296. +custom_op_name||5.007003|
  1297. +custom_op_register||5.013007|
  1298. +custom_op_xop||5.013007|
  1299. +cv_ckproto_len_flags|||
  1300. +cv_clone_into|||
  1301. +cv_clone|||
  1302. +cv_const_sv_or_av|||
  1303. +cv_const_sv||5.004000|
  1304. +cv_dump|||
  1305. +cv_forget_slab|||
  1306. +cv_get_call_checker||5.013006|
  1307. +cv_set_call_checker||5.013006|
  1308. +cv_undef|||
  1309. +cvgv_set|||
  1310. +cvstash_set|||
  1311. +cx_dump||5.005000|
  1312. +cx_dup|||
  1313. +cxinc|||
  1314. +dAXMARK|5.009003||p
  1315. +dAX|5.007002||p
  1316. +dITEMS|5.007002||p
  1317. +dMARK|||
  1318. +dMULTICALL||5.009003|
  1319. +dMY_CXT_SV|5.007003||p
  1320. +dMY_CXT|5.007003||p
  1321. +dNOOP|5.006000||p
  1322. +dORIGMARK|||
  1323. +dSP|||
  1324. +dTHR|5.004050||p
  1325. +dTHXR|5.019002||p
  1326. +dTHXa|5.006000||p
  1327. +dTHXoa|5.006000||p
  1328. +dTHX|5.006000||p
  1329. +dUNDERBAR|5.009002||p
  1330. +dVAR|5.009003||p
  1331. +dXCPT|5.009002||p
  1332. +dXSARGS|||
  1333. +dXSI32|||
  1334. +dXSTARG|5.006000||p
  1335. +deb_curcv|||
  1336. +deb_nocontext|||vn
  1337. +deb_stack_all|||
  1338. +deb_stack_n|||
  1339. +debop||5.005000|
  1340. +debprofdump||5.005000|
  1341. +debprof|||
  1342. +debstackptrs||5.007003|
  1343. +debstack||5.007003|
  1344. +debug_start_match|||
  1345. +deb||5.007003|v
  1346. +defelem_target|||
  1347. +del_sv|||
  1348. +delete_eval_scope|||
  1349. +delimcpy||5.004000|n
  1350. +deprecate_commaless_var_list|||
  1351. +despatch_signals||5.007001|
  1352. +destroy_matcher|||
  1353. +die_nocontext|||vn
  1354. +die_sv||5.013001|
  1355. +die_unwind|||
  1356. +die|||v
  1357. +dirp_dup|||
  1358. +div128|||
  1359. +djSP|||
  1360. +do_aexec5|||
  1361. +do_aexec|||
  1362. +do_aspawn|||
  1363. +do_binmode||5.004050|
  1364. +do_chomp|||
  1365. +do_close|||
  1366. +do_delete_local|||
  1367. +do_dump_pad|||
  1368. +do_eof|||
  1369. +do_exec3|||
  1370. +do_execfree|||
  1371. +do_exec|||
  1372. +do_gv_dump||5.006000|
  1373. +do_gvgv_dump||5.006000|
  1374. +do_hv_dump||5.006000|
  1375. +do_ipcctl|||
  1376. +do_ipcget|||
  1377. +do_join|||
  1378. +do_magic_dump||5.006000|
  1379. +do_msgrcv|||
  1380. +do_msgsnd|||
  1381. +do_ncmp|||
  1382. +do_oddball|||
  1383. +do_op_dump||5.006000|
  1384. +do_op_xmldump|||
  1385. +do_open9||5.006000|
  1386. +do_openn||5.007001|
  1387. +do_open||5.004000|
  1388. +do_pmop_dump||5.006000|
  1389. +do_pmop_xmldump|||
  1390. +do_print|||
  1391. +do_readline|||
  1392. +do_seek|||
  1393. +do_semop|||
  1394. +do_shmio|||
  1395. +do_smartmatch|||
  1396. +do_spawn_nowait|||
  1397. +do_spawn|||
  1398. +do_sprintf|||
  1399. +do_sv_dump||5.006000|
  1400. +do_sysseek|||
  1401. +do_tell|||
  1402. +do_trans_complex_utf8|||
  1403. +do_trans_complex|||
  1404. +do_trans_count_utf8|||
  1405. +do_trans_count|||
  1406. +do_trans_simple_utf8|||
  1407. +do_trans_simple|||
  1408. +do_trans|||
  1409. +do_vecget|||
  1410. +do_vecset|||
  1411. +do_vop|||
  1412. +docatch|||
  1413. +doeval|||
  1414. +dofile|||
  1415. +dofindlabel|||
  1416. +doform|||
  1417. +doing_taint||5.008001|n
  1418. +dooneliner|||
  1419. +doopen_pm|||
  1420. +doparseform|||
  1421. +dopoptoeval|||
  1422. +dopoptogiven|||
  1423. +dopoptolabel|||
  1424. +dopoptoloop|||
  1425. +dopoptosub_at|||
  1426. +dopoptowhen|||
  1427. +doref||5.009003|
  1428. +dounwind|||
  1429. +dowantarray|||
  1430. +dump_all_perl|||
  1431. +dump_all||5.006000|
  1432. +dump_eval||5.006000|
  1433. +dump_exec_pos|||
  1434. +dump_fds|||
  1435. +dump_form||5.006000|
  1436. +dump_indent||5.006000|v
  1437. +dump_mstats|||
  1438. +dump_packsubs_perl|||
  1439. +dump_packsubs||5.006000|
  1440. +dump_sub_perl|||
  1441. +dump_sub||5.006000|
  1442. +dump_sv_child|||
  1443. +dump_trie_interim_list|||
  1444. +dump_trie_interim_table|||
  1445. +dump_trie|||
  1446. +dump_vindent||5.006000|
  1447. +dumpuntil|||
  1448. +dup_attrlist|||
  1449. +emulate_cop_io|||
  1450. +eval_pv|5.006000||p
  1451. +eval_sv|5.006000||p
  1452. +exec_failed|||
  1453. +expect_number|||
  1454. +fbm_compile||5.005000|
  1455. +fbm_instr||5.005000|
  1456. +feature_is_enabled|||
  1457. +filter_add|||
  1458. +filter_del|||
  1459. +filter_gets|||
  1460. +filter_read|||
  1461. +finalize_optree|||
  1462. +finalize_op|||
  1463. +find_and_forget_pmops|||
  1464. +find_array_subscript|||
  1465. +find_beginning|||
  1466. +find_byclass|||
  1467. +find_hash_subscript|||
  1468. +find_in_my_stash|||
  1469. +find_lexical_cv|||
  1470. +find_runcv_where|||
  1471. +find_runcv||5.008001|
  1472. +find_rundefsv2|||
  1473. +find_rundefsvoffset||5.009002|
  1474. +find_rundefsv||5.013002|
  1475. +find_script|||
  1476. +find_uninit_var|||
  1477. +first_symbol|||n
  1478. +foldEQ_latin1||5.013008|n
  1479. +foldEQ_locale||5.013002|n
  1480. +foldEQ_utf8_flags||5.013010|
  1481. +foldEQ_utf8||5.013002|
  1482. +foldEQ||5.013002|n
  1483. +fold_constants|||
  1484. +forbid_setid|||
  1485. +force_ident_maybe_lex|||
  1486. +force_ident|||
  1487. +force_list|||
  1488. +force_next|||
  1489. +force_strict_version|||
  1490. +force_version|||
  1491. +force_word|||
  1492. +forget_pmop|||
  1493. +form_nocontext|||vn
  1494. +form_short_octal_warning|||
  1495. +form||5.004000|v
  1496. +fp_dup|||
  1497. +fprintf_nocontext|||vn
  1498. +free_global_struct|||
  1499. +free_tied_hv_pool|||
  1500. +free_tmps|||
  1501. +gen_constant_list|||
  1502. +get_and_check_backslash_N_name|||
  1503. +get_aux_mg|||
  1504. +get_av|5.006000||p
  1505. +get_context||5.006000|n
  1506. +get_cvn_flags|5.009005||p
  1507. +get_cvs|5.011000||p
  1508. +get_cv|5.006000||p
  1509. +get_db_sub|||
  1510. +get_debug_opts|||
  1511. +get_hash_seed|||
  1512. +get_hv|5.006000||p
  1513. +get_invlist_iter_addr|||
  1514. +get_invlist_offset_addr|||
  1515. +get_invlist_previous_index_addr|||
  1516. +get_mstats|||
  1517. +get_no_modify|||
  1518. +get_num|||
  1519. +get_op_descs||5.005000|
  1520. +get_op_names||5.005000|
  1521. +get_opargs|||
  1522. +get_ppaddr||5.006000|
  1523. +get_re_arg|||
  1524. +get_sv|5.006000||p
  1525. +get_vtbl||5.005030|
  1526. +getcwd_sv||5.007002|
  1527. +getenv_len|||
  1528. +glob_2number|||
  1529. +glob_assign_glob|||
  1530. +glob_assign_ref|||
  1531. +gp_dup|||
  1532. +gp_free|||
  1533. +gp_ref|||
  1534. +grok_bin|5.007003||p
  1535. +grok_bslash_N|||
  1536. +grok_bslash_c|||
  1537. +grok_bslash_o|||
  1538. +grok_bslash_x|||
  1539. +grok_hex|5.007003||p
  1540. +grok_number|5.007002||p
  1541. +grok_numeric_radix|5.007002||p
  1542. +grok_oct|5.007003||p
  1543. +group_end|||
  1544. +gv_AVadd|||
  1545. +gv_HVadd|||
  1546. +gv_IOadd|||
  1547. +gv_SVadd|||
  1548. +gv_add_by_type||5.011000|
  1549. +gv_autoload4||5.004000|
  1550. +gv_autoload_pvn||5.015004|
  1551. +gv_autoload_pv||5.015004|
  1552. +gv_autoload_sv||5.015004|
  1553. +gv_check|||
  1554. +gv_const_sv||5.009003|
  1555. +gv_dump||5.006000|
  1556. +gv_efullname3||5.004000|
  1557. +gv_efullname4||5.006001|
  1558. +gv_efullname|||
  1559. +gv_ename|||
  1560. +gv_fetchfile_flags||5.009005|
  1561. +gv_fetchfile|||
  1562. +gv_fetchmeth_autoload||5.007003|
  1563. +gv_fetchmeth_pv_autoload||5.015004|
  1564. +gv_fetchmeth_pvn_autoload||5.015004|
  1565. +gv_fetchmeth_pvn||5.015004|
  1566. +gv_fetchmeth_pv||5.015004|
  1567. +gv_fetchmeth_sv_autoload||5.015004|
  1568. +gv_fetchmeth_sv||5.015004|
  1569. +gv_fetchmethod_autoload||5.004000|
  1570. +gv_fetchmethod_pv_flags||5.015004|
  1571. +gv_fetchmethod_pvn_flags||5.015004|
  1572. +gv_fetchmethod_sv_flags||5.015004|
  1573. +gv_fetchmethod|||
  1574. +gv_fetchmeth|||
  1575. +gv_fetchpvn_flags|5.009002||p
  1576. +gv_fetchpvs|5.009004||p
  1577. +gv_fetchpv|||
  1578. +gv_fetchsv|5.009002||p
  1579. +gv_fullname3||5.004000|
  1580. +gv_fullname4||5.006001|
  1581. +gv_fullname|||
  1582. +gv_handler||5.007001|
  1583. +gv_init_pvn||5.015004|
  1584. +gv_init_pv||5.015004|
  1585. +gv_init_svtype|||
  1586. +gv_init_sv||5.015004|
  1587. +gv_init|||
  1588. +gv_magicalize_isa|||
  1589. +gv_name_set||5.009004|
  1590. +gv_stashpvn|5.004000||p
  1591. +gv_stashpvs|5.009003||p
  1592. +gv_stashpv|||
  1593. +gv_stashsv|||
  1594. +gv_try_downgrade|||
  1595. +handle_regex_sets|||
  1596. +he_dup|||
  1597. +hek_dup|||
  1598. +hfree_next_entry|||
  1599. +hfreeentries|||
  1600. +hsplit|||
  1601. +hv_assert|||
  1602. +hv_auxinit|||
  1603. +hv_backreferences_p|||
  1604. +hv_clear_placeholders||5.009001|
  1605. +hv_clear|||
  1606. +hv_common_key_len||5.010000|
  1607. +hv_common||5.010000|
  1608. +hv_copy_hints_hv||5.009004|
  1609. +hv_delayfree_ent||5.004000|
  1610. +hv_delete_common|||
  1611. +hv_delete_ent||5.004000|
  1612. +hv_delete|||
  1613. +hv_eiter_p||5.009003|
  1614. +hv_eiter_set||5.009003|
  1615. +hv_ename_add|||
  1616. +hv_ename_delete|||
  1617. +hv_exists_ent||5.004000|
  1618. +hv_exists|||
  1619. +hv_fetch_ent||5.004000|
  1620. +hv_fetchs|5.009003||p
  1621. +hv_fetch|||
  1622. +hv_fill||5.013002|
  1623. +hv_free_ent_ret|||
  1624. +hv_free_ent||5.004000|
  1625. +hv_iterinit|||
  1626. +hv_iterkeysv||5.004000|
  1627. +hv_iterkey|||
  1628. +hv_iternext_flags||5.008000|
  1629. +hv_iternextsv|||
  1630. +hv_iternext|||
  1631. +hv_iterval|||
  1632. +hv_kill_backrefs|||
  1633. +hv_ksplit||5.004000|
  1634. +hv_magic_check|||n
  1635. +hv_magic|||
  1636. +hv_name_set||5.009003|
  1637. +hv_notallowed|||
  1638. +hv_placeholders_get||5.009003|
  1639. +hv_placeholders_p|||
  1640. +hv_placeholders_set||5.009003|
  1641. +hv_rand_set||5.017011|
  1642. +hv_riter_p||5.009003|
  1643. +hv_riter_set||5.009003|
  1644. +hv_scalar||5.009001|
  1645. +hv_store_ent||5.004000|
  1646. +hv_store_flags||5.008000|
  1647. +hv_stores|5.009004||p
  1648. +hv_store|||
  1649. +hv_undef_flags|||
  1650. +hv_undef|||
  1651. +ibcmp_locale||5.004000|
  1652. +ibcmp_utf8||5.007003|
  1653. +ibcmp|||
  1654. +incline|||
  1655. +incpush_if_exists|||
  1656. +incpush_use_sep|||
  1657. +incpush|||
  1658. +ingroup|||
  1659. +init_argv_symbols|||
  1660. +init_constants|||
  1661. +init_dbargs|||
  1662. +init_debugger|||
  1663. +init_global_struct|||
  1664. +init_i18nl10n||5.006000|
  1665. +init_i18nl14n||5.006000|
  1666. +init_ids|||
  1667. +init_interp|||
  1668. +init_main_stash|||
  1669. +init_perllib|||
  1670. +init_postdump_symbols|||
  1671. +init_predump_symbols|||
  1672. +init_stacks||5.005000|
  1673. +init_tm||5.007002|
  1674. +inplace_aassign|||
  1675. +instr|||n
  1676. +intro_my|||
  1677. +intuit_method|||
  1678. +intuit_more|||
  1679. +invert|||
  1680. +invlist_array|||
  1681. +invlist_clone|||
  1682. +invlist_extend|||
  1683. +invlist_highest|||
  1684. +invlist_is_iterating|||
  1685. +invlist_iterfinish|||
  1686. +invlist_iterinit|||
  1687. +invlist_iternext|||
  1688. +invlist_max|||
  1689. +invlist_previous_index|||
  1690. +invlist_set_len|||
  1691. +invlist_set_previous_index|||
  1692. +invlist_trim|||
  1693. +invoke_exception_hook|||
  1694. +io_close|||
  1695. +isALNUMC|5.006000||p
  1696. +isALNUM_lazy|||
  1697. +isALPHANUMERIC||5.017008|
  1698. +isALPHA|||
  1699. +isASCII|5.006000|5.006000|p
  1700. +isBLANK|5.006001||p
  1701. +isCNTRL|5.006000|5.006000|p
  1702. +isDIGIT|||
  1703. +isFOO_lc|||
  1704. +isFOO_utf8_lc|||
  1705. +isGRAPH|5.006000||p
  1706. +isGV_with_GP|5.009004||p
  1707. +isIDCONT||5.017008|
  1708. +isIDFIRST_lazy|||
  1709. +isIDFIRST|||
  1710. +isLOWER|||
  1711. +isOCTAL||5.013005|
  1712. +isPRINT|5.004000||p
  1713. +isPSXSPC|5.006001||p
  1714. +isPUNCT|5.006000||p
  1715. +isSPACE|||
  1716. +isUPPER|||
  1717. +isWORDCHAR||5.013006|
  1718. +isXDIGIT|5.006000||p
  1719. +is_an_int|||
  1720. +is_ascii_string||5.011000|n
  1721. +is_cur_LC_category_utf8|||
  1722. +is_handle_constructor|||n
  1723. +is_list_assignment|||
  1724. +is_lvalue_sub||5.007001|
  1725. +is_uni_alnum_lc||5.006000|
  1726. +is_uni_alnumc_lc||5.017007|
  1727. +is_uni_alnumc||5.017007|
  1728. +is_uni_alnum||5.006000|
  1729. +is_uni_alpha_lc||5.006000|
  1730. +is_uni_alpha||5.006000|
  1731. +is_uni_ascii_lc||5.006000|
  1732. +is_uni_ascii||5.006000|
  1733. +is_uni_blank_lc||5.017002|
  1734. +is_uni_blank||5.017002|
  1735. +is_uni_cntrl_lc||5.006000|
  1736. +is_uni_cntrl||5.006000|
  1737. +is_uni_digit_lc||5.006000|
  1738. +is_uni_digit||5.006000|
  1739. +is_uni_graph_lc||5.006000|
  1740. +is_uni_graph||5.006000|
  1741. +is_uni_idfirst_lc||5.006000|
  1742. +is_uni_idfirst||5.006000|
  1743. +is_uni_lower_lc||5.006000|
  1744. +is_uni_lower||5.006000|
  1745. +is_uni_print_lc||5.006000|
  1746. +is_uni_print||5.006000|
  1747. +is_uni_punct_lc||5.006000|
  1748. +is_uni_punct||5.006000|
  1749. +is_uni_space_lc||5.006000|
  1750. +is_uni_space||5.006000|
  1751. +is_uni_upper_lc||5.006000|
  1752. +is_uni_upper||5.006000|
  1753. +is_uni_xdigit_lc||5.006000|
  1754. +is_uni_xdigit||5.006000|
  1755. +is_utf8_alnumc||5.017007|
  1756. +is_utf8_alnum||5.006000|
  1757. +is_utf8_alpha||5.006000|
  1758. +is_utf8_ascii||5.006000|
  1759. +is_utf8_blank||5.017002|
  1760. +is_utf8_char_buf||5.015008|n
  1761. +is_utf8_char_slow|||n
  1762. +is_utf8_char||5.006000|n
  1763. +is_utf8_cntrl||5.006000|
  1764. +is_utf8_common|||
  1765. +is_utf8_digit||5.006000|
  1766. +is_utf8_graph||5.006000|
  1767. +is_utf8_idcont||5.008000|
  1768. +is_utf8_idfirst||5.006000|
  1769. +is_utf8_lower||5.006000|
  1770. +is_utf8_mark||5.006000|
  1771. +is_utf8_perl_space||5.011001|
  1772. +is_utf8_perl_word||5.011001|
  1773. +is_utf8_posix_digit||5.011001|
  1774. +is_utf8_print||5.006000|
  1775. +is_utf8_punct||5.006000|
  1776. +is_utf8_space||5.006000|
  1777. +is_utf8_string_loclen||5.009003|n
  1778. +is_utf8_string_loc||5.008001|n
  1779. +is_utf8_string||5.006001|n
  1780. +is_utf8_upper||5.006000|
  1781. +is_utf8_xdigit||5.006000|
  1782. +is_utf8_xidcont||5.013010|
  1783. +is_utf8_xidfirst||5.013010|
  1784. +isa_lookup|||
  1785. +items|||n
  1786. +ix|||n
  1787. +jmaybe|||
  1788. +join_exact|||
  1789. +keyword_plugin_standard|||
  1790. +keyword|||
  1791. +leave_scope|||
  1792. +lex_bufutf8||5.011002|
  1793. +lex_discard_to||5.011002|
  1794. +lex_grow_linestr||5.011002|
  1795. +lex_next_chunk||5.011002|
  1796. +lex_peek_unichar||5.011002|
  1797. +lex_read_space||5.011002|
  1798. +lex_read_to||5.011002|
  1799. +lex_read_unichar||5.011002|
  1800. +lex_start||5.009005|
  1801. +lex_stuff_pvn||5.011002|
  1802. +lex_stuff_pvs||5.013005|
  1803. +lex_stuff_pv||5.013006|
  1804. +lex_stuff_sv||5.011002|
  1805. +lex_unstuff||5.011002|
  1806. +listkids|||
  1807. +list|||
  1808. +load_module_nocontext|||vn
  1809. +load_module|5.006000||pv
  1810. +localize|||
  1811. +looks_like_bool|||
  1812. +looks_like_number|||
  1813. +lop|||
  1814. +mPUSHi|5.009002||p
  1815. +mPUSHn|5.009002||p
  1816. +mPUSHp|5.009002||p
  1817. +mPUSHs|5.010001||p
  1818. +mPUSHu|5.009002||p
  1819. +mXPUSHi|5.009002||p
  1820. +mXPUSHn|5.009002||p
  1821. +mXPUSHp|5.009002||p
  1822. +mXPUSHs|5.010001||p
  1823. +mXPUSHu|5.009002||p
  1824. +mad_free|||
  1825. +madlex|||
  1826. +madparse|||
  1827. +magic_clear_all_env|||
  1828. +magic_cleararylen_p|||
  1829. +magic_clearenv|||
  1830. +magic_clearhints|||
  1831. +magic_clearhint|||
  1832. +magic_clearisa|||
  1833. +magic_clearpack|||
  1834. +magic_clearsig|||
  1835. +magic_copycallchecker|||
  1836. +magic_dump||5.006000|
  1837. +magic_existspack|||
  1838. +magic_freearylen_p|||
  1839. +magic_freeovrld|||
  1840. +magic_getarylen|||
  1841. +magic_getdefelem|||
  1842. +magic_getnkeys|||
  1843. +magic_getpack|||
  1844. +magic_getpos|||
  1845. +magic_getsig|||
  1846. +magic_getsubstr|||
  1847. +magic_gettaint|||
  1848. +magic_getuvar|||
  1849. +magic_getvec|||
  1850. +magic_get|||
  1851. +magic_killbackrefs|||
  1852. +magic_methcall1|||
  1853. +magic_methcall|||v
  1854. +magic_methpack|||
  1855. +magic_nextpack|||
  1856. +magic_regdata_cnt|||
  1857. +magic_regdatum_get|||
  1858. +magic_regdatum_set|||
  1859. +magic_scalarpack|||
  1860. +magic_set_all_env|||
  1861. +magic_setarylen|||
  1862. +magic_setcollxfrm|||
  1863. +magic_setdbline|||
  1864. +magic_setdefelem|||
  1865. +magic_setenv|||
  1866. +magic_sethint|||
  1867. +magic_setisa|||
  1868. +magic_setmglob|||
  1869. +magic_setnkeys|||
  1870. +magic_setpack|||
  1871. +magic_setpos|||
  1872. +magic_setregexp|||
  1873. +magic_setsig|||
  1874. +magic_setsubstr|||
  1875. +magic_settaint|||
  1876. +magic_setutf8|||
  1877. +magic_setuvar|||
  1878. +magic_setvec|||
  1879. +magic_set|||
  1880. +magic_sizepack|||
  1881. +magic_wipepack|||
  1882. +make_matcher|||
  1883. +make_trie_failtable|||
  1884. +make_trie|||
  1885. +malloc_good_size|||n
  1886. +malloced_size|||n
  1887. +malloc||5.007002|n
  1888. +markstack_grow|||
  1889. +matcher_matches_sv|||
  1890. +mayberelocate|||
  1891. +measure_struct|||
  1892. +memEQs|5.009005||p
  1893. +memEQ|5.004000||p
  1894. +memNEs|5.009005||p
  1895. +memNE|5.004000||p
  1896. +mem_collxfrm|||
  1897. +mem_log_common|||n
  1898. +mess_alloc|||
  1899. +mess_nocontext|||vn
  1900. +mess_sv||5.013001|
  1901. +mess||5.006000|v
  1902. +method_common|||
  1903. +mfree||5.007002|n
  1904. +mg_clear|||
  1905. +mg_copy|||
  1906. +mg_dup|||
  1907. +mg_find_mglob|||
  1908. +mg_findext||5.013008|
  1909. +mg_find|||
  1910. +mg_free_type||5.013006|
  1911. +mg_free|||
  1912. +mg_get|||
  1913. +mg_length||5.005000|
  1914. +mg_localize|||
  1915. +mg_magical|||
  1916. +mg_set|||
  1917. +mg_size||5.005000|
  1918. +mini_mktime||5.007002|
  1919. +minus_v|||
  1920. +missingterm|||
  1921. +mode_from_discipline|||
  1922. +modkids|||
  1923. +more_bodies|||
  1924. +more_sv|||
  1925. +moreswitches|||
  1926. +mro_clean_isarev|||
  1927. +mro_gather_and_rename|||
  1928. +mro_get_from_name||5.010001|
  1929. +mro_get_linear_isa_dfs|||
  1930. +mro_get_linear_isa||5.009005|
  1931. +mro_get_private_data||5.010001|
  1932. +mro_isa_changed_in|||
  1933. +mro_meta_dup|||
  1934. +mro_meta_init|||
  1935. +mro_method_changed_in||5.009005|
  1936. +mro_package_moved|||
  1937. +mro_register||5.010001|
  1938. +mro_set_mro||5.010001|
  1939. +mro_set_private_data||5.010001|
  1940. +mul128|||
  1941. +mulexp10|||n
  1942. +my_atof2||5.007002|
  1943. +my_atof||5.006000|
  1944. +my_attrs|||
  1945. +my_bcopy|||n
  1946. +my_bzero|||n
  1947. +my_chsize|||
  1948. +my_clearenv|||
  1949. +my_cxt_index|||
  1950. +my_cxt_init|||
  1951. +my_dirfd||5.009005|
  1952. +my_exit_jump|||
  1953. +my_exit|||
  1954. +my_failure_exit||5.004000|
  1955. +my_fflush_all||5.006000|
  1956. +my_fork||5.007003|n
  1957. +my_kid|||
  1958. +my_lstat_flags|||
  1959. +my_lstat||5.019003|
  1960. +my_memcmp|||n
  1961. +my_memset||5.004000|n
  1962. +my_pclose||5.004000|
  1963. +my_popen_list||5.007001|
  1964. +my_popen||5.004000|
  1965. +my_setenv|||
  1966. +my_snprintf|5.009004||pvn
  1967. +my_socketpair||5.007003|n
  1968. +my_sprintf|5.009003||pvn
  1969. +my_stat_flags|||
  1970. +my_stat||5.019003|
  1971. +my_strftime||5.007002|
  1972. +my_strlcat|5.009004||pn
  1973. +my_strlcpy|5.009004||pn
  1974. +my_unexec|||
  1975. +my_vsnprintf||5.009004|n
  1976. +need_utf8|||n
  1977. +newANONATTRSUB||5.006000|
  1978. +newANONHASH|||
  1979. +newANONLIST|||
  1980. +newANONSUB|||
  1981. +newASSIGNOP|||
  1982. +newATTRSUB_flags|||
  1983. +newATTRSUB||5.006000|
  1984. +newAVREF|||
  1985. +newAV|||
  1986. +newBINOP|||
  1987. +newCONDOP|||
  1988. +newCONSTSUB_flags||5.015006|
  1989. +newCONSTSUB|5.004050||p
  1990. +newCVREF|||
  1991. +newDEFSVOP|||
  1992. +newFORM|||
  1993. +newFOROP||5.013007|
  1994. +newGIVENOP||5.009003|
  1995. +newGIVWHENOP|||
  1996. +newGP|||
  1997. +newGVOP|||
  1998. +newGVREF|||
  1999. +newGVgen_flags||5.015004|
  2000. +newGVgen|||
  2001. +newHVREF|||
  2002. +newHVhv||5.005000|
  2003. +newHV|||
  2004. +newIO|||
  2005. +newLISTOP|||
  2006. +newLOGOP|||
  2007. +newLOOPEX|||
  2008. +newLOOPOP|||
  2009. +newMADPROP|||
  2010. +newMADsv|||
  2011. +newMYSUB||5.017004|
  2012. +newNULLLIST|||
  2013. +newOP|||
  2014. +newPADOP|||
  2015. +newPMOP|||
  2016. +newPROG|||
  2017. +newPVOP|||
  2018. +newRANGE|||
  2019. +newRV_inc|5.004000||p
  2020. +newRV_noinc|5.004000||p
  2021. +newRV|||
  2022. +newSLICEOP|||
  2023. +newSTATEOP|||
  2024. +newSTUB|||
  2025. +newSUB|||
  2026. +newSVOP|||
  2027. +newSVREF|||
  2028. +newSV_type|5.009005||p
  2029. +newSVhek||5.009003|
  2030. +newSViv|||
  2031. +newSVnv|||
  2032. +newSVpadname||5.017004|
  2033. +newSVpv_share||5.013006|
  2034. +newSVpvf_nocontext|||vn
  2035. +newSVpvf||5.004000|v
  2036. +newSVpvn_flags|5.010001||p
  2037. +newSVpvn_share|5.007001||p
  2038. +newSVpvn_utf8|5.010001||p
  2039. +newSVpvn|5.004050||p
  2040. +newSVpvs_flags|5.010001||p
  2041. +newSVpvs_share|5.009003||p
  2042. +newSVpvs|5.009003||p
  2043. +newSVpv|||
  2044. +newSVrv|||
  2045. +newSVsv|||
  2046. +newSVuv|5.006000||p
  2047. +newSV|||
  2048. +newTOKEN|||
  2049. +newUNOP|||
  2050. +newWHENOP||5.009003|
  2051. +newWHILEOP||5.013007|
  2052. +newXS_flags||5.009004|
  2053. +newXS_len_flags|||
  2054. +newXSproto||5.006000|
  2055. +newXS||5.006000|
  2056. +new_collate||5.006000|
  2057. +new_constant|||
  2058. +new_ctype||5.006000|
  2059. +new_he|||
  2060. +new_logop|||
  2061. +new_numeric||5.006000|
  2062. +new_stackinfo||5.005000|
  2063. +new_version||5.009000|
  2064. +new_warnings_bitfield|||
  2065. +next_symbol|||
  2066. +nextargv|||
  2067. +nextchar|||
  2068. +ninstr|||n
  2069. +no_bareword_allowed|||
  2070. +no_fh_allowed|||
  2071. +no_op|||
  2072. +not_a_number|||
  2073. +not_incrementable|||
  2074. +nothreadhook||5.008000|
  2075. +nuke_stacks|||
  2076. +num_overflow|||n
  2077. +oopsAV|||
  2078. +oopsHV|||
  2079. +op_append_elem||5.013006|
  2080. +op_append_list||5.013006|
  2081. +op_clear|||
  2082. +op_const_sv|||
  2083. +op_contextualize||5.013006|
  2084. +op_dump||5.006000|
  2085. +op_free|||
  2086. +op_getmad_weak|||
  2087. +op_getmad|||
  2088. +op_integerize|||
  2089. +op_linklist||5.013006|
  2090. +op_lvalue_flags|||
  2091. +op_lvalue||5.013007|
  2092. +op_null||5.007002|
  2093. +op_prepend_elem||5.013006|
  2094. +op_refcnt_dec|||
  2095. +op_refcnt_inc|||
  2096. +op_refcnt_lock||5.009002|
  2097. +op_refcnt_unlock||5.009002|
  2098. +op_scope||5.013007|
  2099. +op_std_init|||
  2100. +op_unscope|||
  2101. +op_xmldump|||
  2102. +open_script|||
  2103. +opslab_force_free|||
  2104. +opslab_free_nopad|||
  2105. +opslab_free|||
  2106. +pMY_CXT_|5.007003||p
  2107. +pMY_CXT|5.007003||p
  2108. +pTHX_|5.006000||p
  2109. +pTHX|5.006000||p
  2110. +packWARN|5.007003||p
  2111. +pack_cat||5.007003|
  2112. +pack_rec|||
  2113. +package_version|||
  2114. +package|||
  2115. +packlist||5.008001|
  2116. +pad_add_anon||5.008001|
  2117. +pad_add_name_pvn||5.015001|
  2118. +pad_add_name_pvs||5.015001|
  2119. +pad_add_name_pv||5.015001|
  2120. +pad_add_name_sv||5.015001|
  2121. +pad_alloc_name|||
  2122. +pad_alloc|||
  2123. +pad_block_start|||
  2124. +pad_check_dup|||
  2125. +pad_compname_type||5.009003|
  2126. +pad_findlex|||
  2127. +pad_findmy_pvn||5.015001|
  2128. +pad_findmy_pvs||5.015001|
  2129. +pad_findmy_pv||5.015001|
  2130. +pad_findmy_sv||5.015001|
  2131. +pad_fixup_inner_anons|||
  2132. +pad_free|||
  2133. +pad_leavemy|||
  2134. +pad_new||5.008001|
  2135. +pad_peg|||n
  2136. +pad_push|||
  2137. +pad_reset|||
  2138. +pad_setsv|||
  2139. +pad_sv|||
  2140. +pad_swipe|||
  2141. +pad_tidy||5.008001|
  2142. +padlist_dup|||
  2143. +padlist_store|||
  2144. +parse_arithexpr||5.013008|
  2145. +parse_barestmt||5.013007|
  2146. +parse_block||5.013007|
  2147. +parse_body|||
  2148. +parse_fullexpr||5.013008|
  2149. +parse_fullstmt||5.013005|
  2150. +parse_ident|||
  2151. +parse_label||5.013007|
  2152. +parse_listexpr||5.013008|
  2153. +parse_lparen_question_flags|||
  2154. +parse_stmtseq||5.013006|
  2155. +parse_termexpr||5.013008|
  2156. +parse_unicode_opts|||
  2157. +parser_dup|||
  2158. +parser_free_nexttoke_ops|||
  2159. +parser_free|||
  2160. +path_is_searchable|||n
  2161. +peep|||
  2162. +pending_ident|||
  2163. +perl_alloc_using|||n
  2164. +perl_alloc|||n
  2165. +perl_clone_using|||n
  2166. +perl_clone|||n
  2167. +perl_construct|||n
  2168. +perl_destruct||5.007003|n
  2169. +perl_free|||n
  2170. +perl_parse||5.006000|n
  2171. +perl_run|||n
  2172. +pidgone|||
  2173. +pm_description|||
  2174. +pmop_dump||5.006000|
  2175. +pmop_xmldump|||
  2176. +pmruntime|||
  2177. +pmtrans|||
  2178. +pop_scope|||
  2179. +populate_isa|||v
  2180. +pregcomp||5.009005|
  2181. +pregexec|||
  2182. +pregfree2||5.011000|
  2183. +pregfree|||
  2184. +prepend_madprops|||
  2185. +prescan_version||5.011004|
  2186. +printbuf|||
  2187. +printf_nocontext|||vn
  2188. +process_special_blocks|||
  2189. +ptr_hash|||n
  2190. +ptr_table_clear||5.009005|
  2191. +ptr_table_fetch||5.009005|
  2192. +ptr_table_find|||n
  2193. +ptr_table_free||5.009005|
  2194. +ptr_table_new||5.009005|
  2195. +ptr_table_split||5.009005|
  2196. +ptr_table_store||5.009005|
  2197. +push_scope|||
  2198. +put_byte|||
  2199. +put_latin1_charclass_innards|||
  2200. +pv_display|5.006000||p
  2201. +pv_escape|5.009004||p
  2202. +pv_pretty|5.009004||p
  2203. +pv_uni_display||5.007003|
  2204. +qerror|||
  2205. +qsortsvu|||
  2206. +re_compile||5.009005|
  2207. +re_croak2|||
  2208. +re_dup_guts|||
  2209. +re_intuit_start||5.019001|
  2210. +re_intuit_string||5.006000|
  2211. +re_op_compile|||
  2212. +readpipe_override|||
  2213. +realloc||5.007002|n
  2214. +reentrant_free||5.019003|
  2215. +reentrant_init||5.019003|
  2216. +reentrant_retry||5.019003|vn
  2217. +reentrant_size||5.019003|
  2218. +ref_array_or_hash|||
  2219. +refcounted_he_chain_2hv|||
  2220. +refcounted_he_fetch_pvn|||
  2221. +refcounted_he_fetch_pvs|||
  2222. +refcounted_he_fetch_pv|||
  2223. +refcounted_he_fetch_sv|||
  2224. +refcounted_he_free|||
  2225. +refcounted_he_inc|||
  2226. +refcounted_he_new_pvn|||
  2227. +refcounted_he_new_pvs|||
  2228. +refcounted_he_new_pv|||
  2229. +refcounted_he_new_sv|||
  2230. +refcounted_he_value|||
  2231. +refkids|||
  2232. +refto|||
  2233. +ref||5.019003|
  2234. +reg_check_named_buff_matched|||
  2235. +reg_named_buff_all||5.009005|
  2236. +reg_named_buff_exists||5.009005|
  2237. +reg_named_buff_fetch||5.009005|
  2238. +reg_named_buff_firstkey||5.009005|
  2239. +reg_named_buff_iter|||
  2240. +reg_named_buff_nextkey||5.009005|
  2241. +reg_named_buff_scalar||5.009005|
  2242. +reg_named_buff|||
  2243. +reg_node|||
  2244. +reg_numbered_buff_fetch|||
  2245. +reg_numbered_buff_length|||
  2246. +reg_numbered_buff_store|||
  2247. +reg_qr_package|||
  2248. +reg_recode|||
  2249. +reg_scan_name|||
  2250. +reg_skipcomment|||
  2251. +reg_temp_copy|||
  2252. +reganode|||
  2253. +regatom|||
  2254. +regbranch|||
  2255. +regclass_swash||5.009004|
  2256. +regclass|||
  2257. +regcppop|||
  2258. +regcppush|||
  2259. +regcurly|||
  2260. +regdump_extflags|||
  2261. +regdump_intflags|||
  2262. +regdump||5.005000|
  2263. +regdupe_internal|||
  2264. +regexec_flags||5.005000|
  2265. +regfree_internal||5.009005|
  2266. +reghop3|||n
  2267. +reghop4|||n
  2268. +reghopmaybe3|||n
  2269. +reginclass|||
  2270. +reginitcolors||5.006000|
  2271. +reginsert|||
  2272. +regmatch|||
  2273. +regnext||5.005000|
  2274. +regpatws|||n
  2275. +regpiece|||
  2276. +regpposixcc|||
  2277. +regprop|||
  2278. +regrepeat|||
  2279. +regtail_study|||
  2280. +regtail|||
  2281. +regtry|||
  2282. +reguni|||
  2283. +regwhite|||n
  2284. +reg|||
  2285. +repeatcpy|||n
  2286. +report_evil_fh|||
  2287. +report_redefined_cv|||
  2288. +report_uninit|||
  2289. +report_wrongway_fh|||
  2290. +require_pv||5.006000|
  2291. +require_tie_mod|||
  2292. +restore_magic|||
  2293. +rninstr|||n
  2294. +rpeep|||
  2295. +rsignal_restore|||
  2296. +rsignal_save|||
  2297. +rsignal_state||5.004000|
  2298. +rsignal||5.004000|
  2299. +run_body|||
  2300. +run_user_filter|||
  2301. +runops_debug||5.005000|
  2302. +runops_standard||5.005000|
  2303. +rv2cv_op_cv||5.013006|
  2304. +rvpv_dup|||
  2305. +rxres_free|||
  2306. +rxres_restore|||
  2307. +rxres_save|||
  2308. +safesyscalloc||5.006000|n
  2309. +safesysfree||5.006000|n
  2310. +safesysmalloc||5.006000|n
  2311. +safesysrealloc||5.006000|n
  2312. +same_dirent|||
  2313. +save_I16||5.004000|
  2314. +save_I32|||
  2315. +save_I8||5.006000|
  2316. +save_adelete||5.011000|
  2317. +save_aelem_flags||5.011000|
  2318. +save_aelem||5.004050|
  2319. +save_alloc||5.006000|
  2320. +save_aptr|||
  2321. +save_ary|||
  2322. +save_bool||5.008001|
  2323. +save_clearsv|||
  2324. +save_delete|||
  2325. +save_destructor_x||5.006000|
  2326. +save_destructor||5.006000|
  2327. +save_freeop|||
  2328. +save_freepv|||
  2329. +save_freesv|||
  2330. +save_generic_pvref||5.006001|
  2331. +save_generic_svref||5.005030|
  2332. +save_gp||5.004000|
  2333. +save_hash|||
  2334. +save_hdelete||5.011000|
  2335. +save_hek_flags|||n
  2336. +save_helem_flags||5.011000|
  2337. +save_helem||5.004050|
  2338. +save_hints||5.010001|
  2339. +save_hptr|||
  2340. +save_int|||
  2341. +save_item|||
  2342. +save_iv||5.005000|
  2343. +save_lines|||
  2344. +save_list|||
  2345. +save_long|||
  2346. +save_magic_flags|||
  2347. +save_mortalizesv||5.007001|
  2348. +save_nogv|||
  2349. +save_op||5.005000|
  2350. +save_padsv_and_mortalize||5.010001|
  2351. +save_pptr|||
  2352. +save_pushi32ptr||5.010001|
  2353. +save_pushptri32ptr|||
  2354. +save_pushptrptr||5.010001|
  2355. +save_pushptr||5.010001|
  2356. +save_re_context||5.006000|
  2357. +save_scalar_at|||
  2358. +save_scalar|||
  2359. +save_set_svflags||5.009000|
  2360. +save_shared_pvref||5.007003|
  2361. +save_sptr|||
  2362. +save_svref|||
  2363. +save_vptr||5.006000|
  2364. +savepvn|||
  2365. +savepvs||5.009003|
  2366. +savepv|||
  2367. +savesharedpvn||5.009005|
  2368. +savesharedpvs||5.013006|
  2369. +savesharedpv||5.007003|
  2370. +savesharedsvpv||5.013006|
  2371. +savestack_grow_cnt||5.008001|
  2372. +savestack_grow|||
  2373. +savesvpv||5.009002|
  2374. +sawparens|||
  2375. +scalar_mod_type|||n
  2376. +scalarboolean|||
  2377. +scalarkids|||
  2378. +scalarseq|||
  2379. +scalarvoid|||
  2380. +scalar|||
  2381. +scan_bin||5.006000|
  2382. +scan_commit|||
  2383. +scan_const|||
  2384. +scan_formline|||
  2385. +scan_heredoc|||
  2386. +scan_hex|||
  2387. +scan_ident|||
  2388. +scan_inputsymbol|||
  2389. +scan_num||5.007001|
  2390. +scan_oct|||
  2391. +scan_pat|||
  2392. +scan_str|||
  2393. +scan_subst|||
  2394. +scan_trans|||
  2395. +scan_version||5.009001|
  2396. +scan_vstring||5.009005|
  2397. +scan_word|||
  2398. +screaminstr||5.005000|
  2399. +search_const|||
  2400. +seed||5.008001|
  2401. +sequence_num|||
  2402. +set_context||5.006000|n
  2403. +set_numeric_local||5.006000|
  2404. +set_numeric_radix||5.006000|
  2405. +set_numeric_standard||5.006000|
  2406. +setdefout|||
  2407. +share_hek_flags|||
  2408. +share_hek||5.004000|
  2409. +si_dup|||
  2410. +sighandler|||n
  2411. +simplify_sort|||
  2412. +skipspace0|||
  2413. +skipspace1|||
  2414. +skipspace2|||
  2415. +skipspace_flags|||
  2416. +softref2xv|||
  2417. +sortcv_stacked|||
  2418. +sortcv_xsub|||
  2419. +sortcv|||
  2420. +sortsv_flags||5.009003|
  2421. +sortsv||5.007003|
  2422. +space_join_names_mortal|||
  2423. +ss_dup|||
  2424. +stack_grow|||
  2425. +start_force|||
  2426. +start_glob|||
  2427. +start_subparse||5.004000|
  2428. +stdize_locale|||
  2429. +strEQ|||
  2430. +strGE|||
  2431. +strGT|||
  2432. +strLE|||
  2433. +strLT|||
  2434. +strNE|||
  2435. +str_to_version||5.006000|
  2436. +strip_return|||
  2437. +strnEQ|||
  2438. +strnNE|||
  2439. +study_chunk|||
  2440. +sub_crush_depth|||
  2441. +sublex_done|||
  2442. +sublex_push|||
  2443. +sublex_start|||
  2444. +sv_2bool_flags||5.013006|
  2445. +sv_2bool|||
  2446. +sv_2cv|||
  2447. +sv_2io|||
  2448. +sv_2iuv_common|||
  2449. +sv_2iuv_non_preserve|||
  2450. +sv_2iv_flags||5.009001|
  2451. +sv_2iv|||
  2452. +sv_2mortal|||
  2453. +sv_2num|||
  2454. +sv_2nv_flags||5.013001|
  2455. +sv_2pv_flags|5.007002||p
  2456. +sv_2pv_nolen|5.006000||p
  2457. +sv_2pvbyte_nolen|5.006000||p
  2458. +sv_2pvbyte|5.006000||p
  2459. +sv_2pvutf8_nolen||5.006000|
  2460. +sv_2pvutf8||5.006000|
  2461. +sv_2pv|||
  2462. +sv_2uv_flags||5.009001|
  2463. +sv_2uv|5.004000||p
  2464. +sv_add_arena|||
  2465. +sv_add_backref|||
  2466. +sv_backoff|||
  2467. +sv_bless|||
  2468. +sv_cat_decode||5.008001|
  2469. +sv_catpv_flags||5.013006|
  2470. +sv_catpv_mg|5.004050||p
  2471. +sv_catpv_nomg||5.013006|
  2472. +sv_catpvf_mg_nocontext|||pvn
  2473. +sv_catpvf_mg|5.006000|5.004000|pv
  2474. +sv_catpvf_nocontext|||vn
  2475. +sv_catpvf||5.004000|v
  2476. +sv_catpvn_flags||5.007002|
  2477. +sv_catpvn_mg|5.004050||p
  2478. +sv_catpvn_nomg|5.007002||p
  2479. +sv_catpvn|||
  2480. +sv_catpvs_flags||5.013006|
  2481. +sv_catpvs_mg||5.013006|
  2482. +sv_catpvs_nomg||5.013006|
  2483. +sv_catpvs|5.009003||p
  2484. +sv_catpv|||
  2485. +sv_catsv_flags||5.007002|
  2486. +sv_catsv_mg|5.004050||p
  2487. +sv_catsv_nomg|5.007002||p
  2488. +sv_catsv|||
  2489. +sv_catxmlpvn|||
  2490. +sv_catxmlpv|||
  2491. +sv_catxmlsv|||
  2492. +sv_chop|||
  2493. +sv_clean_all|||
  2494. +sv_clean_objs|||
  2495. +sv_clear|||
  2496. +sv_cmp_flags||5.013006|
  2497. +sv_cmp_locale_flags||5.013006|
  2498. +sv_cmp_locale||5.004000|
  2499. +sv_cmp|||
  2500. +sv_collxfrm_flags||5.013006|
  2501. +sv_collxfrm|||
  2502. +sv_copypv_flags||5.017002|
  2503. +sv_copypv_nomg||5.017002|
  2504. +sv_copypv|||
  2505. +sv_dec_nomg||5.013002|
  2506. +sv_dec|||
  2507. +sv_del_backref|||
  2508. +sv_derived_from_pvn||5.015004|
  2509. +sv_derived_from_pv||5.015004|
  2510. +sv_derived_from_sv||5.015004|
  2511. +sv_derived_from||5.004000|
  2512. +sv_destroyable||5.010000|
  2513. +sv_display|||
  2514. +sv_does_pvn||5.015004|
  2515. +sv_does_pv||5.015004|
  2516. +sv_does_sv||5.015004|
  2517. +sv_does||5.009004|
  2518. +sv_dump|||
  2519. +sv_dup_common|||
  2520. +sv_dup_inc_multiple|||
  2521. +sv_dup_inc|||
  2522. +sv_dup|||
  2523. +sv_eq_flags||5.013006|
  2524. +sv_eq|||
  2525. +sv_exp_grow|||
  2526. +sv_force_normal_flags||5.007001|
  2527. +sv_force_normal||5.006000|
  2528. +sv_free2|||
  2529. +sv_free_arenas|||
  2530. +sv_free|||
  2531. +sv_gets||5.004000|
  2532. +sv_grow|||
  2533. +sv_i_ncmp|||
  2534. +sv_inc_nomg||5.013002|
  2535. +sv_inc|||
  2536. +sv_insert_flags||5.010001|
  2537. +sv_insert|||
  2538. +sv_isa|||
  2539. +sv_isobject|||
  2540. +sv_iv||5.005000|
  2541. +sv_kill_backrefs|||
  2542. +sv_len_utf8_nomg|||
  2543. +sv_len_utf8||5.006000|
  2544. +sv_len|||
  2545. +sv_magic_portable|5.019003|5.004000|p
  2546. +sv_magicext_mglob|||
  2547. +sv_magicext||5.007003|
  2548. +sv_magic|||
  2549. +sv_mortalcopy_flags|||
  2550. +sv_mortalcopy|||
  2551. +sv_ncmp|||
  2552. +sv_newmortal|||
  2553. +sv_newref|||
  2554. +sv_nolocking||5.007003|
  2555. +sv_nosharing||5.007003|
  2556. +sv_nounlocking|||
  2557. +sv_nv||5.005000|
  2558. +sv_peek||5.005000|
  2559. +sv_pos_b2u_flags||5.019003|
  2560. +sv_pos_b2u_midway|||
  2561. +sv_pos_b2u||5.006000|
  2562. +sv_pos_u2b_cached|||
  2563. +sv_pos_u2b_flags||5.011005|
  2564. +sv_pos_u2b_forwards|||n
  2565. +sv_pos_u2b_midway|||n
  2566. +sv_pos_u2b||5.006000|
  2567. +sv_pvbyten_force||5.006000|
  2568. +sv_pvbyten||5.006000|
  2569. +sv_pvbyte||5.006000|
  2570. +sv_pvn_force_flags|5.007002||p
  2571. +sv_pvn_force|||
  2572. +sv_pvn_nomg|5.007003|5.005000|p
  2573. +sv_pvn||5.005000|
  2574. +sv_pvutf8n_force||5.006000|
  2575. +sv_pvutf8n||5.006000|
  2576. +sv_pvutf8||5.006000|
  2577. +sv_pv||5.006000|
  2578. +sv_recode_to_utf8||5.007003|
  2579. +sv_reftype|||
  2580. +sv_ref|||
  2581. +sv_release_COW|||
  2582. +sv_replace|||
  2583. +sv_report_used|||
  2584. +sv_resetpvn|||
  2585. +sv_reset|||
  2586. +sv_rvweaken||5.006000|
  2587. +sv_sethek|||
  2588. +sv_setiv_mg|5.004050||p
  2589. +sv_setiv|||
  2590. +sv_setnv_mg|5.006000||p
  2591. +sv_setnv|||
  2592. +sv_setpv_mg|5.004050||p
  2593. +sv_setpvf_mg_nocontext|||pvn
  2594. +sv_setpvf_mg|5.006000|5.004000|pv
  2595. +sv_setpvf_nocontext|||vn
  2596. +sv_setpvf||5.004000|v
  2597. +sv_setpviv_mg||5.008001|
  2598. +sv_setpviv||5.008001|
  2599. +sv_setpvn_mg|5.004050||p
  2600. +sv_setpvn|||
  2601. +sv_setpvs_mg||5.013006|
  2602. +sv_setpvs|5.009004||p
  2603. +sv_setpv|||
  2604. +sv_setref_iv|||
  2605. +sv_setref_nv|||
  2606. +sv_setref_pvn|||
  2607. +sv_setref_pvs||5.019003|
  2608. +sv_setref_pv|||
  2609. +sv_setref_uv||5.007001|
  2610. +sv_setsv_cow|||
  2611. +sv_setsv_flags||5.007002|
  2612. +sv_setsv_mg|5.004050||p
  2613. +sv_setsv_nomg|5.007002||p
  2614. +sv_setsv|||
  2615. +sv_setuv_mg|5.004050||p
  2616. +sv_setuv|5.004000||p
  2617. +sv_tainted||5.004000|
  2618. +sv_taint||5.004000|
  2619. +sv_true||5.005000|
  2620. +sv_unglob|||
  2621. +sv_uni_display||5.007003|
  2622. +sv_unmagicext||5.013008|
  2623. +sv_unmagic|||
  2624. +sv_unref_flags||5.007001|
  2625. +sv_unref|||
  2626. +sv_untaint||5.004000|
  2627. +sv_upgrade|||
  2628. +sv_usepvn_flags||5.009004|
  2629. +sv_usepvn_mg|5.004050||p
  2630. +sv_usepvn|||
  2631. +sv_utf8_decode||5.006000|
  2632. +sv_utf8_downgrade||5.006000|
  2633. +sv_utf8_encode||5.006000|
  2634. +sv_utf8_upgrade_flags_grow||5.011000|
  2635. +sv_utf8_upgrade_flags||5.007002|
  2636. +sv_utf8_upgrade_nomg||5.007002|
  2637. +sv_utf8_upgrade||5.007001|
  2638. +sv_uv|5.005000||p
  2639. +sv_vcatpvf_mg|5.006000|5.004000|p
  2640. +sv_vcatpvfn_flags||5.017002|
  2641. +sv_vcatpvfn||5.004000|
  2642. +sv_vcatpvf|5.006000|5.004000|p
  2643. +sv_vsetpvf_mg|5.006000|5.004000|p
  2644. +sv_vsetpvfn||5.004000|
  2645. +sv_vsetpvf|5.006000|5.004000|p
  2646. +sv_xmlpeek|||
  2647. +svtype|||
  2648. +swallow_bom|||
  2649. +swash_fetch||5.007002|
  2650. +swash_init||5.006000|
  2651. +swatch_get|||
  2652. +sys_init3||5.010000|n
  2653. +sys_init||5.010000|n
  2654. +sys_intern_clear|||
  2655. +sys_intern_dup|||
  2656. +sys_intern_init|||
  2657. +sys_term||5.010000|n
  2658. +taint_env|||
  2659. +taint_proper|||
  2660. +tied_method|||v
  2661. +tmps_grow||5.006000|
  2662. +toFOLD_uni||5.007003|
  2663. +toFOLD_utf8||5.019001|
  2664. +toFOLD||5.019001|
  2665. +toLOWER_L1||5.019001|
  2666. +toLOWER_LC||5.004000|
  2667. +toLOWER_uni||5.007003|
  2668. +toLOWER_utf8||5.015007|
  2669. +toLOWER|||
  2670. +toTITLE_uni||5.007003|
  2671. +toTITLE_utf8||5.015007|
  2672. +toTITLE||5.019001|
  2673. +toUPPER_uni||5.007003|
  2674. +toUPPER_utf8||5.015007|
  2675. +toUPPER||5.004000|
  2676. +to_byte_substr|||
  2677. +to_lower_latin1|||
  2678. +to_uni_fold||5.007003|
  2679. +to_uni_lower_lc||5.006000|
  2680. +to_uni_lower||5.007003|
  2681. +to_uni_title_lc||5.006000|
  2682. +to_uni_title||5.007003|
  2683. +to_uni_upper_lc||5.006000|
  2684. +to_uni_upper||5.007003|
  2685. +to_utf8_case||5.007003|
  2686. +to_utf8_fold||5.015007|
  2687. +to_utf8_lower||5.015007|
  2688. +to_utf8_substr|||
  2689. +to_utf8_title||5.015007|
  2690. +to_utf8_upper||5.015007|
  2691. +token_free|||
  2692. +token_getmad|||
  2693. +tokenize_use|||
  2694. +tokeq|||
  2695. +tokereport|||
  2696. +too_few_arguments_pv|||
  2697. +too_few_arguments_sv|||
  2698. +too_many_arguments_pv|||
  2699. +too_many_arguments_sv|||
  2700. +translate_substr_offsets|||
  2701. +try_amagic_bin|||
  2702. +try_amagic_un|||
  2703. +uiv_2buf|||n
  2704. +unlnk|||
  2705. +unpack_rec|||
  2706. +unpack_str||5.007003|
  2707. +unpackstring||5.008001|
  2708. +unreferenced_to_tmp_stack|||
  2709. +unshare_hek_or_pvn|||
  2710. +unshare_hek|||
  2711. +unsharepvn||5.004000|
  2712. +unwind_handler_stack|||
  2713. +update_debugger_info|||
  2714. +upg_version||5.009005|
  2715. +usage|||
  2716. +utf16_textfilter|||
  2717. +utf16_to_utf8_reversed||5.006001|
  2718. +utf16_to_utf8||5.006001|
  2719. +utf8_distance||5.006000|
  2720. +utf8_hop||5.006000|
  2721. +utf8_length||5.007001|
  2722. +utf8_mg_len_cache_update|||
  2723. +utf8_mg_pos_cache_update|||
  2724. +utf8_to_bytes||5.006001|
  2725. +utf8_to_uvchr_buf||5.015009|
  2726. +utf8_to_uvchr||5.007001|
  2727. +utf8_to_uvuni_buf||5.015009|
  2728. +utf8_to_uvuni||5.007001|
  2729. +utf8n_to_uvchr|||
  2730. +utf8n_to_uvuni||5.007001|
  2731. +utilize|||
  2732. +uvchr_to_utf8_flags||5.007003|
  2733. +uvchr_to_utf8|||
  2734. +uvuni_to_utf8_flags||5.007003|
  2735. +uvuni_to_utf8||5.007001|
  2736. +valid_utf8_to_uvchr|||
  2737. +valid_utf8_to_uvuni||5.015009|
  2738. +validate_proto|||
  2739. +validate_suid|||
  2740. +varname|||
  2741. +vcmp||5.009000|
  2742. +vcroak||5.006000|
  2743. +vdeb||5.007003|
  2744. +vform||5.006000|
  2745. +visit|||
  2746. +vivify_defelem|||
  2747. +vivify_ref|||
  2748. +vload_module|5.006000||p
  2749. +vmess||5.006000|
  2750. +vnewSVpvf|5.006000|5.004000|p
  2751. +vnormal||5.009002|
  2752. +vnumify||5.009000|
  2753. +vstringify||5.009000|
  2754. +vverify||5.009003|
  2755. +vwarner||5.006000|
  2756. +vwarn||5.006000|
  2757. +wait4pid|||
  2758. +warn_nocontext|||vn
  2759. +warn_sv||5.013001|
  2760. +warner_nocontext|||vn
  2761. +warner|5.006000|5.004000|pv
  2762. +warn|||v
  2763. +was_lvalue_sub|||
  2764. +watch|||
  2765. +whichsig_pvn||5.015004|
  2766. +whichsig_pv||5.015004|
  2767. +whichsig_sv||5.015004|
  2768. +whichsig|||
  2769. +win32_croak_not_implemented|||n
  2770. +with_queued_errors|||
  2771. +wrap_op_checker||5.015008|
  2772. +write_to_stderr|||
  2773. +xmldump_all_perl|||
  2774. +xmldump_all|||
  2775. +xmldump_attr|||
  2776. +xmldump_eval|||
  2777. +xmldump_form|||
  2778. +xmldump_indent|||v
  2779. +xmldump_packsubs_perl|||
  2780. +xmldump_packsubs|||
  2781. +xmldump_sub_perl|||
  2782. +xmldump_sub|||
  2783. +xmldump_vindent|||
  2784. +xs_apiversion_bootcheck|||
  2785. +xs_version_bootcheck|||
  2786. +yyerror_pvn|||
  2787. +yyerror_pv|||
  2788. +yyerror|||
  2789. +yylex|||
  2790. +yyparse|||
  2791. +yyunlex|||
  2792. +yywarn|||
  2793. +);
  2794. +
  2795. +if (exists $opt{'list-unsupported'}) {
  2796. + my $f;
  2797. + for $f (sort { lc $a cmp lc $b } keys %API) {
  2798. + next unless $API{$f}{todo};
  2799. + print "$f ", '.'x(40-length($f)), " ", format_version($API{$f}{todo}), "\n";
  2800. + }
  2801. + exit 0;
  2802. +}
  2803. +
  2804. +# Scan for possible replacement candidates
  2805. +
  2806. +my(%replace, %need, %hints, %warnings, %depends);
  2807. +my $replace = 0;
  2808. +my($hint, $define, $function);
  2809. +
  2810. +sub find_api
  2811. +{
  2812. + my $code = shift;
  2813. + $code =~ s{
  2814. + / (?: \*[^*]*\*+(?:[^$ccs][^*]*\*+)* / | /[^\r\n]*)
  2815. + | "[^"\\]*(?:\\.[^"\\]*)*"
  2816. + | '[^'\\]*(?:\\.[^'\\]*)*' }{}egsx;
  2817. + grep { exists $API{$_} } $code =~ /(\w+)/mg;
  2818. +}
  2819. +
  2820. +while (<DATA>) {
  2821. + if ($hint) {
  2822. + my $h = $hint->[0] eq 'Hint' ? \%hints : \%warnings;
  2823. + if (m{^\s*\*\s(.*?)\s*$}) {
  2824. + for (@{$hint->[1]}) {
  2825. + $h->{$_} ||= ''; # suppress warning with older perls
  2826. + $h->{$_} .= "$1\n";
  2827. + }
  2828. + }
  2829. + else { undef $hint }
  2830. + }
  2831. +
  2832. + $hint = [$1, [split /,?\s+/, $2]]
  2833. + if m{^\s*$rccs\s+(Hint|Warning):\s+(\w+(?:,?\s+\w+)*)\s*$};
  2834. +
  2835. + if ($define) {
  2836. + if ($define->[1] =~ /\\$/) {
  2837. + $define->[1] .= $_;
  2838. + }
  2839. + else {
  2840. + if (exists $API{$define->[0]} && $define->[1] !~ /^DPPP_\(/) {
  2841. + my @n = find_api($define->[1]);
  2842. + push @{$depends{$define->[0]}}, @n if @n
  2843. + }
  2844. + undef $define;
  2845. + }
  2846. + }
  2847. +
  2848. + $define = [$1, $2] if m{^\s*#\s*define\s+(\w+)(?:\([^)]*\))?\s+(.*)};
  2849. +
  2850. + if ($function) {
  2851. + if (/^}/) {
  2852. + if (exists $API{$function->[0]}) {
  2853. + my @n = find_api($function->[1]);
  2854. + push @{$depends{$function->[0]}}, @n if @n
  2855. + }
  2856. + undef $function;
  2857. + }
  2858. + else {
  2859. + $function->[1] .= $_;
  2860. + }
  2861. + }
  2862. +
  2863. + $function = [$1, ''] if m{^DPPP_\(my_(\w+)\)};
  2864. +
  2865. + $replace = $1 if m{^\s*$rccs\s+Replace:\s+(\d+)\s+$rcce\s*$};
  2866. + $replace{$2} = $1 if $replace and m{^\s*#\s*define\s+(\w+)(?:\([^)]*\))?\s+(\w+)};
  2867. + $replace{$2} = $1 if m{^\s*#\s*define\s+(\w+)(?:\([^)]*\))?\s+(\w+).*$rccs\s+Replace\s+$rcce};
  2868. + $replace{$1} = $2 if m{^\s*$rccs\s+Replace (\w+) with (\w+)\s+$rcce\s*$};
  2869. +
  2870. + if (m{^\s*$rccs\s+(\w+(\s*,\s*\w+)*)\s+depends\s+on\s+(\w+(\s*,\s*\w+)*)\s+$rcce\s*$}) {
  2871. + my @deps = map { s/\s+//g; $_ } split /,/, $3;
  2872. + my $d;
  2873. + for $d (map { s/\s+//g; $_ } split /,/, $1) {
  2874. + push @{$depends{$d}}, @deps;
  2875. + }
  2876. + }
  2877. +
  2878. + $need{$1} = 1 if m{^#if\s+defined\(NEED_(\w+)(?:_GLOBAL)?\)};
  2879. +}
  2880. +
  2881. +for (values %depends) {
  2882. + my %s;
  2883. + $_ = [sort grep !$s{$_}++, @$_];
  2884. +}
  2885. +
  2886. +if (exists $opt{'api-info'}) {
  2887. + my $f;
  2888. + my $count = 0;
  2889. + my $match = $opt{'api-info'} =~ m!^/(.*)/$! ? $1 : "^\Q$opt{'api-info'}\E\$";
  2890. + for $f (sort { lc $a cmp lc $b } keys %API) {
  2891. + next unless $f =~ /$match/;
  2892. + print "\n=== $f ===\n\n";
  2893. + my $info = 0;
  2894. + if ($API{$f}{base} || $API{$f}{todo}) {
  2895. + my $base = format_version($API{$f}{base} || $API{$f}{todo});
  2896. + print "Supported at least starting from perl-$base.\n";
  2897. + $info++;
  2898. + }
  2899. + if ($API{$f}{provided}) {
  2900. + my $todo = $API{$f}{todo} ? format_version($API{$f}{todo}) : "5.003";
  2901. + print "Support by $ppport provided back to perl-$todo.\n";
  2902. + print "Support needs to be explicitly requested by NEED_$f.\n" if exists $need{$f};
  2903. + print "Depends on: ", join(', ', @{$depends{$f}}), ".\n" if exists $depends{$f};
  2904. + print "\n$hints{$f}" if exists $hints{$f};
  2905. + print "\nWARNING:\n$warnings{$f}" if exists $warnings{$f};
  2906. + $info++;
  2907. + }
  2908. + print "No portability information available.\n" unless $info;
  2909. + $count++;
  2910. + }
  2911. + $count or print "Found no API matching '$opt{'api-info'}'.";
  2912. + print "\n";
  2913. + exit 0;
  2914. +}
  2915. +
  2916. +if (exists $opt{'list-provided'}) {
  2917. + my $f;
  2918. + for $f (sort { lc $a cmp lc $b } keys %API) {
  2919. + next unless $API{$f}{provided};
  2920. + my @flags;
  2921. + push @flags, 'explicit' if exists $need{$f};
  2922. + push @flags, 'depend' if exists $depends{$f};
  2923. + push @flags, 'hint' if exists $hints{$f};
  2924. + push @flags, 'warning' if exists $warnings{$f};
  2925. + my $flags = @flags ? ' ['.join(', ', @flags).']' : '';
  2926. + print "$f$flags\n";
  2927. + }
  2928. + exit 0;
  2929. +}
  2930. +
  2931. +my @files;
  2932. +my @srcext = qw( .xs .c .h .cc .cpp -c.inc -xs.inc );
  2933. +my $srcext = join '|', map { quotemeta $_ } @srcext;
  2934. +
  2935. +if (@ARGV) {
  2936. + my %seen;
  2937. + for (@ARGV) {
  2938. + if (-e) {
  2939. + if (-f) {
  2940. + push @files, $_ unless $seen{$_}++;
  2941. + }
  2942. + else { warn "'$_' is not a file.\n" }
  2943. + }
  2944. + else {
  2945. + my @new = grep { -f } glob $_
  2946. + or warn "'$_' does not exist.\n";
  2947. + push @files, grep { !$seen{$_}++ } @new;
  2948. + }
  2949. + }
  2950. +}
  2951. +else {
  2952. + eval {
  2953. + require File::Find;
  2954. + File::Find::find(sub {
  2955. + $File::Find::name =~ /($srcext)$/i
  2956. + and push @files, $File::Find::name;
  2957. + }, '.');
  2958. + };
  2959. + if ($@) {
  2960. + @files = map { glob "*$_" } @srcext;
  2961. + }
  2962. +}
  2963. +
  2964. +if (!@ARGV || $opt{filter}) {
  2965. + my(@in, @out);
  2966. + my %xsc = map { /(.*)\.xs$/ ? ("$1.c" => 1, "$1.cc" => 1) : () } @files;
  2967. + for (@files) {
  2968. + my $out = exists $xsc{$_} || /\b\Q$ppport\E$/i || !/($srcext)$/i;
  2969. + push @{ $out ? \@out : \@in }, $_;
  2970. + }
  2971. + if (@ARGV && @out) {
  2972. + warning("Skipping the following files (use --nofilter to avoid this):\n| ", join "\n| ", @out);
  2973. + }
  2974. + @files = @in;
  2975. +}
  2976. +
  2977. +die "No input files given!\n" unless @files;
  2978. +
  2979. +my(%files, %global, %revreplace);
  2980. +%revreplace = reverse %replace;
  2981. +my $filename;
  2982. +my $patch_opened = 0;
  2983. +
  2984. +for $filename (@files) {
  2985. + unless (open IN, "<$filename") {
  2986. + warn "Unable to read from $filename: $!\n";
  2987. + next;
  2988. + }
  2989. +
  2990. + info("Scanning $filename ...");
  2991. +
  2992. + my $c = do { local $/; <IN> };
  2993. + close IN;
  2994. +
  2995. + my %file = (orig => $c, changes => 0);
  2996. +
  2997. + # Temporarily remove C/XS comments and strings from the code
  2998. + my @ccom;
  2999. +
  3000. + $c =~ s{
  3001. + ( ^$HS*\#$HS*include\b[^\r\n]+\b(?:\Q$ppport\E|XSUB\.h)\b[^\r\n]*
  3002. + | ^$HS*\#$HS*(?:define|elif|if(?:def)?)\b[^\r\n]* )
  3003. + | ( ^$HS*\#[^\r\n]*
  3004. + | "[^"\\]*(?:\\.[^"\\]*)*"
  3005. + | '[^'\\]*(?:\\.[^'\\]*)*'
  3006. + | / (?: \*[^*]*\*+(?:[^$ccs][^*]*\*+)* / | /[^\r\n]* ) )
  3007. + }{ defined $2 and push @ccom, $2;
  3008. + defined $1 ? $1 : "$ccs$#ccom$cce" }mgsex;
  3009. +
  3010. + $file{ccom} = \@ccom;
  3011. + $file{code} = $c;
  3012. + $file{has_inc_ppport} = $c =~ /^$HS*#$HS*include[^\r\n]+\b\Q$ppport\E\b/m;
  3013. +
  3014. + my $func;
  3015. +
  3016. + for $func (keys %API) {
  3017. + my $match = $func;
  3018. + $match .= "|$revreplace{$func}" if exists $revreplace{$func};
  3019. + if ($c =~ /\b(?:Perl_)?($match)\b/) {
  3020. + $file{uses_replace}{$1}++ if exists $revreplace{$func} && $1 eq $revreplace{$func};
  3021. + $file{uses_Perl}{$func}++ if $c =~ /\bPerl_$func\b/;
  3022. + if (exists $API{$func}{provided}) {
  3023. + $file{uses_provided}{$func}++;
  3024. + if (!exists $API{$func}{base} || $API{$func}{base} > $opt{'compat-version'}) {
  3025. + $file{uses}{$func}++;
  3026. + my @deps = rec_depend($func);
  3027. + if (@deps) {
  3028. + $file{uses_deps}{$func} = \@deps;
  3029. + for (@deps) {
  3030. + $file{uses}{$_} = 0 unless exists $file{uses}{$_};
  3031. + }
  3032. + }
  3033. + for ($func, @deps) {
  3034. + $file{needs}{$_} = 'static' if exists $need{$_};
  3035. + }
  3036. + }
  3037. + }
  3038. + if (exists $API{$func}{todo} && $API{$func}{todo} > $opt{'compat-version'}) {
  3039. + if ($c =~ /\b$func\b/) {
  3040. + $file{uses_todo}{$func}++;
  3041. + }
  3042. + }
  3043. + }
  3044. + }
  3045. +
  3046. + while ($c =~ /^$HS*#$HS*define$HS+(NEED_(\w+?)(_GLOBAL)?)\b/mg) {
  3047. + if (exists $need{$2}) {
  3048. + $file{defined $3 ? 'needed_global' : 'needed_static'}{$2}++;
  3049. + }
  3050. + else { warning("Possibly wrong #define $1 in $filename") }
  3051. + }
  3052. +
  3053. + for (qw(uses needs uses_todo needed_global needed_static)) {
  3054. + for $func (keys %{$file{$_}}) {
  3055. + push @{$global{$_}{$func}}, $filename;
  3056. + }
  3057. + }
  3058. +
  3059. + $files{$filename} = \%file;
  3060. +}
  3061. +
  3062. +# Globally resolve NEED_'s
  3063. +my $need;
  3064. +for $need (keys %{$global{needs}}) {
  3065. + if (@{$global{needs}{$need}} > 1) {
  3066. + my @targets = @{$global{needs}{$need}};
  3067. + my @t = grep $files{$_}{needed_global}{$need}, @targets;
  3068. + @targets = @t if @t;
  3069. + @t = grep /\.xs$/i, @targets;
  3070. + @targets = @t if @t;
  3071. + my $target = shift @targets;
  3072. + $files{$target}{needs}{$need} = 'global';
  3073. + for (@{$global{needs}{$need}}) {
  3074. + $files{$_}{needs}{$need} = 'extern' if $_ ne $target;
  3075. + }
  3076. + }
  3077. +}
  3078. +
  3079. +for $filename (@files) {
  3080. + exists $files{$filename} or next;
  3081. +
  3082. + info("=== Analyzing $filename ===");
  3083. +
  3084. + my %file = %{$files{$filename}};
  3085. + my $func;
  3086. + my $c = $file{code};
  3087. + my $warnings = 0;
  3088. +
  3089. + for $func (sort keys %{$file{uses_Perl}}) {
  3090. + if ($API{$func}{varargs}) {
  3091. + unless ($API{$func}{nothxarg}) {
  3092. + my $changes = ($c =~ s{\b(Perl_$func\s*\(\s*)(?!aTHX_?)(\)|[^\s)]*\))}
  3093. + { $1 . ($2 eq ')' ? 'aTHX' : 'aTHX_ ') . $2 }ge);
  3094. + if ($changes) {
  3095. + warning("Doesn't pass interpreter argument aTHX to Perl_$func");
  3096. + $file{changes} += $changes;
  3097. + }
  3098. + }
  3099. + }
  3100. + else {
  3101. + warning("Uses Perl_$func instead of $func");
  3102. + $file{changes} += ($c =~ s{\bPerl_$func(\s*)\((\s*aTHX_?)?\s*}
  3103. + {$func$1(}g);
  3104. + }
  3105. + }
  3106. +
  3107. + for $func (sort keys %{$file{uses_replace}}) {
  3108. + warning("Uses $func instead of $replace{$func}");
  3109. + $file{changes} += ($c =~ s/\b$func\b/$replace{$func}/g);
  3110. + }
  3111. +
  3112. + for $func (sort keys %{$file{uses_provided}}) {
  3113. + if ($file{uses}{$func}) {
  3114. + if (exists $file{uses_deps}{$func}) {
  3115. + diag("Uses $func, which depends on ", join(', ', @{$file{uses_deps}{$func}}));
  3116. + }
  3117. + else {
  3118. + diag("Uses $func");
  3119. + }
  3120. + }
  3121. + $warnings += hint($func);
  3122. + }
  3123. +
  3124. + unless ($opt{quiet}) {
  3125. + for $func (sort keys %{$file{uses_todo}}) {
  3126. + print "*** WARNING: Uses $func, which may not be portable below perl ",
  3127. + format_version($API{$func}{todo}), ", even with '$ppport'\n";
  3128. + $warnings++;
  3129. + }
  3130. + }
  3131. +
  3132. + for $func (sort keys %{$file{needed_static}}) {
  3133. + my $message = '';
  3134. + if (not exists $file{uses}{$func}) {
  3135. + $message = "No need to define NEED_$func if $func is never used";
  3136. + }
  3137. + elsif (exists $file{needs}{$func} && $file{needs}{$func} ne 'static') {
  3138. + $message = "No need to define NEED_$func when already needed globally";
  3139. + }
  3140. + if ($message) {
  3141. + diag($message);
  3142. + $file{changes} += ($c =~ s/^$HS*#$HS*define$HS+NEED_$func\b.*$LF//mg);
  3143. + }
  3144. + }
  3145. +
  3146. + for $func (sort keys %{$file{needed_global}}) {
  3147. + my $message = '';
  3148. + if (not exists $global{uses}{$func}) {
  3149. + $message = "No need to define NEED_${func}_GLOBAL if $func is never used";
  3150. + }
  3151. + elsif (exists $file{needs}{$func}) {
  3152. + if ($file{needs}{$func} eq 'extern') {
  3153. + $message = "No need to define NEED_${func}_GLOBAL when already needed globally";
  3154. + }
  3155. + elsif ($file{needs}{$func} eq 'static') {
  3156. + $message = "No need to define NEED_${func}_GLOBAL when only used in this file";
  3157. + }
  3158. + }
  3159. + if ($message) {
  3160. + diag($message);
  3161. + $file{changes} += ($c =~ s/^$HS*#$HS*define$HS+NEED_${func}_GLOBAL\b.*$LF//mg);
  3162. + }
  3163. + }
  3164. +
  3165. + $file{needs_inc_ppport} = keys %{$file{uses}};
  3166. +
  3167. + if ($file{needs_inc_ppport}) {
  3168. + my $pp = '';
  3169. +
  3170. + for $func (sort keys %{$file{needs}}) {
  3171. + my $type = $file{needs}{$func};
  3172. + next if $type eq 'extern';
  3173. + my $suffix = $type eq 'global' ? '_GLOBAL' : '';
  3174. + unless (exists $file{"needed_$type"}{$func}) {
  3175. + if ($type eq 'global') {
  3176. + diag("Files [@{$global{needs}{$func}}] need $func, adding global request");
  3177. + }
  3178. + else {
  3179. + diag("File needs $func, adding static request");
  3180. + }
  3181. + $pp .= "#define NEED_$func$suffix\n";
  3182. + }
  3183. + }
  3184. +
  3185. + if ($pp && ($c =~ s/^(?=$HS*#$HS*define$HS+NEED_\w+)/$pp/m)) {
  3186. + $pp = '';
  3187. + $file{changes}++;
  3188. + }
  3189. +
  3190. + unless ($file{has_inc_ppport}) {
  3191. + diag("Needs to include '$ppport'");
  3192. + $pp .= qq(#include "$ppport"\n)
  3193. + }
  3194. +
  3195. + if ($pp) {
  3196. + $file{changes} += ($c =~ s/^($HS*#$HS*define$HS+NEED_\w+.*?)^/$1$pp/ms)
  3197. + || ($c =~ s/^(?=$HS*#$HS*include.*\Q$ppport\E)/$pp/m)
  3198. + || ($c =~ s/^($HS*#$HS*include.*XSUB.*\s*?)^/$1$pp/m)
  3199. + || ($c =~ s/^/$pp/);
  3200. + }
  3201. + }
  3202. + else {
  3203. + if ($file{has_inc_ppport}) {
  3204. + diag("No need to include '$ppport'");
  3205. + $file{changes} += ($c =~ s/^$HS*?#$HS*include.*\Q$ppport\E.*?$LF//m);
  3206. + }
  3207. + }
  3208. +
  3209. + # put back in our C comments
  3210. + my $ix;
  3211. + my $cppc = 0;
  3212. + my @ccom = @{$file{ccom}};
  3213. + for $ix (0 .. $#ccom) {
  3214. + if (!$opt{cplusplus} && $ccom[$ix] =~ s!^//!!) {
  3215. + $cppc++;
  3216. + $file{changes} += $c =~ s/$rccs$ix$rcce/$ccs$ccom[$ix] $cce/;
  3217. + }
  3218. + else {
  3219. + $c =~ s/$rccs$ix$rcce/$ccom[$ix]/;
  3220. + }
  3221. + }
  3222. +
  3223. + if ($cppc) {
  3224. + my $s = $cppc != 1 ? 's' : '';
  3225. + warning("Uses $cppc C++ style comment$s, which is not portable");
  3226. + }
  3227. +
  3228. + my $s = $warnings != 1 ? 's' : '';
  3229. + my $warn = $warnings ? " ($warnings warning$s)" : '';
  3230. + info("Analysis completed$warn");
  3231. +
  3232. + if ($file{changes}) {
  3233. + if (exists $opt{copy}) {
  3234. + my $newfile = "$filename$opt{copy}";
  3235. + if (-e $newfile) {
  3236. + error("'$newfile' already exists, refusing to write copy of '$filename'");
  3237. + }
  3238. + else {
  3239. + local *F;
  3240. + if (open F, ">$newfile") {
  3241. + info("Writing copy of '$filename' with changes to '$newfile'");
  3242. + print F $c;
  3243. + close F;
  3244. + }
  3245. + else {
  3246. + error("Cannot open '$newfile' for writing: $!");
  3247. + }
  3248. + }
  3249. + }
  3250. + elsif (exists $opt{patch} || $opt{changes}) {
  3251. + if (exists $opt{patch}) {
  3252. + unless ($patch_opened) {
  3253. + if (open PATCH, ">$opt{patch}") {
  3254. + $patch_opened = 1;
  3255. + }
  3256. + else {
  3257. + error("Cannot open '$opt{patch}' for writing: $!");
  3258. + delete $opt{patch};
  3259. + $opt{changes} = 1;
  3260. + goto fallback;
  3261. + }
  3262. + }
  3263. + mydiff(\*PATCH, $filename, $c);
  3264. + }
  3265. + else {
  3266. +fallback:
  3267. + info("Suggested changes:");
  3268. + mydiff(\*STDOUT, $filename, $c);
  3269. + }
  3270. + }
  3271. + else {
  3272. + my $s = $file{changes} == 1 ? '' : 's';
  3273. + info("$file{changes} potentially required change$s detected");
  3274. + }
  3275. + }
  3276. + else {
  3277. + info("Looks good");
  3278. + }
  3279. +}
  3280. +
  3281. +close PATCH if $patch_opened;
  3282. +
  3283. +exit 0;
  3284. +
  3285. +
  3286. +sub try_use { eval "use @_;"; return $@ eq '' }
  3287. +
  3288. +sub mydiff
  3289. +{
  3290. + local *F = shift;
  3291. + my($file, $str) = @_;
  3292. + my $diff;
  3293. +
  3294. + if (exists $opt{diff}) {
  3295. + $diff = run_diff($opt{diff}, $file, $str);
  3296. + }
  3297. +
  3298. + if (!defined $diff and try_use('Text::Diff')) {
  3299. + $diff = Text::Diff::diff($file, \$str, { STYLE => 'Unified' });
  3300. + $diff = <<HEADER . $diff;
  3301. +--- $file
  3302. ++++ $file.patched
  3303. +HEADER
  3304. + }
  3305. +
  3306. + if (!defined $diff) {
  3307. + $diff = run_diff('diff -u', $file, $str);
  3308. + }
  3309. +
  3310. + if (!defined $diff) {
  3311. + $diff = run_diff('diff', $file, $str);
  3312. + }
  3313. +
  3314. + if (!defined $diff) {
  3315. + error("Cannot generate a diff. Please install Text::Diff or use --copy.");
  3316. + return;
  3317. + }
  3318. +
  3319. + print F $diff;
  3320. +}
  3321. +
  3322. +sub run_diff
  3323. +{
  3324. + my($prog, $file, $str) = @_;
  3325. + my $tmp = 'dppptemp';
  3326. + my $suf = 'aaa';
  3327. + my $diff = '';
  3328. + local *F;
  3329. +
  3330. + while (-e "$tmp.$suf") { $suf++ }
  3331. + $tmp = "$tmp.$suf";
  3332. +
  3333. + if (open F, ">$tmp") {
  3334. + print F $str;
  3335. + close F;
  3336. +
  3337. + if (open F, "$prog $file $tmp |") {
  3338. + while (<F>) {
  3339. + s/\Q$tmp\E/$file.patched/;
  3340. + $diff .= $_;
  3341. + }
  3342. + close F;
  3343. + unlink $tmp;
  3344. + return $diff;
  3345. + }
  3346. +
  3347. + unlink $tmp;
  3348. + }
  3349. + else {
  3350. + error("Cannot open '$tmp' for writing: $!");
  3351. + }
  3352. +
  3353. + return undef;
  3354. +}
  3355. +
  3356. +sub rec_depend
  3357. +{
  3358. + my($func, $seen) = @_;
  3359. + return () unless exists $depends{$func};
  3360. + $seen = {%{$seen||{}}};
  3361. + return () if $seen->{$func}++;
  3362. + my %s;
  3363. + grep !$s{$_}++, map { ($_, rec_depend($_, $seen)) } @{$depends{$func}};
  3364. +}
  3365. +
  3366. +sub parse_version
  3367. +{
  3368. + my $ver = shift;
  3369. +
  3370. + if ($ver =~ /^(\d+)\.(\d+)\.(\d+)$/) {
  3371. + return ($1, $2, $3);
  3372. + }
  3373. + elsif ($ver !~ /^\d+\.[\d_]+$/) {
  3374. + die "cannot parse version '$ver'\n";
  3375. + }
  3376. +
  3377. + $ver =~ s/_//g;
  3378. + $ver =~ s/$/000000/;
  3379. +
  3380. + my($r,$v,$s) = $ver =~ /(\d+)\.(\d{3})(\d{3})/;
  3381. +
  3382. + $v = int $v;
  3383. + $s = int $s;
  3384. +
  3385. + if ($r < 5 || ($r == 5 && $v < 6)) {
  3386. + if ($s % 10) {
  3387. + die "cannot parse version '$ver'\n";
  3388. + }
  3389. + }
  3390. +
  3391. + return ($r, $v, $s);
  3392. +}
  3393. +
  3394. +sub format_version
  3395. +{
  3396. + my $ver = shift;
  3397. +
  3398. + $ver =~ s/$/000000/;
  3399. + my($r,$v,$s) = $ver =~ /(\d+)\.(\d{3})(\d{3})/;
  3400. +
  3401. + $v = int $v;
  3402. + $s = int $s;
  3403. +
  3404. + if ($r < 5 || ($r == 5 && $v < 6)) {
  3405. + if ($s % 10) {
  3406. + die "invalid version '$ver'\n";
  3407. + }
  3408. + $s /= 10;
  3409. +
  3410. + $ver = sprintf "%d.%03d", $r, $v;
  3411. + $s > 0 and $ver .= sprintf "_%02d", $s;
  3412. +
  3413. + return $ver;
  3414. + }
  3415. +
  3416. + return sprintf "%d.%d.%d", $r, $v, $s;
  3417. +}
  3418. +
  3419. +sub info
  3420. +{
  3421. + $opt{quiet} and return;
  3422. + print @_, "\n";
  3423. +}
  3424. +
  3425. +sub diag
  3426. +{
  3427. + $opt{quiet} and return;
  3428. + $opt{diag} and print @_, "\n";
  3429. +}
  3430. +
  3431. +sub warning
  3432. +{
  3433. + $opt{quiet} and return;
  3434. + print "*** ", @_, "\n";
  3435. +}
  3436. +
  3437. +sub error
  3438. +{
  3439. + print "*** ERROR: ", @_, "\n";
  3440. +}
  3441. +
  3442. +my %given_hints;
  3443. +my %given_warnings;
  3444. +sub hint
  3445. +{
  3446. + $opt{quiet} and return;
  3447. + my $func = shift;
  3448. + my $rv = 0;
  3449. + if (exists $warnings{$func} && !$given_warnings{$func}++) {
  3450. + my $warn = $warnings{$func};
  3451. + $warn =~ s!^!*** !mg;
  3452. + print "*** WARNING: $func\n", $warn;
  3453. + $rv++;
  3454. + }
  3455. + if ($opt{hints} && exists $hints{$func} && !$given_hints{$func}++) {
  3456. + my $hint = $hints{$func};
  3457. + $hint =~ s/^/ /mg;
  3458. + print " --- hint for $func ---\n", $hint;
  3459. + }
  3460. + $rv;
  3461. +}
  3462. +
  3463. +sub usage
  3464. +{
  3465. + my($usage) = do { local(@ARGV,$/)=($0); <> } =~ /^=head\d$HS+SYNOPSIS\s*^(.*?)\s*^=/ms;
  3466. + my %M = ( 'I' => '*' );
  3467. + $usage =~ s/^\s*perl\s+\S+/$^X $0/;
  3468. + $usage =~ s/([A-Z])<([^>]+)>/$M{$1}$2$M{$1}/g;
  3469. +
  3470. + print <<ENDUSAGE;
  3471. +
  3472. +Usage: $usage
  3473. +
  3474. +See perldoc $0 for details.
  3475. +
  3476. +ENDUSAGE
  3477. +
  3478. + exit 2;
  3479. +}
  3480. +
  3481. +sub strip
  3482. +{
  3483. + my $self = do { local(@ARGV,$/)=($0); <> };
  3484. + my($copy) = $self =~ /^=head\d\s+COPYRIGHT\s*^(.*?)^=\w+/ms;
  3485. + $copy =~ s/^(?=\S+)/ /gms;
  3486. + $self =~ s/^$HS+Do NOT edit.*?(?=^-)/$copy/ms;
  3487. + $self =~ s/^SKIP.*(?=^__DATA__)/SKIP
  3488. +if (\@ARGV && \$ARGV[0] eq '--unstrip') {
  3489. + eval { require Devel::PPPort };
  3490. + \$@ and die "Cannot require Devel::PPPort, please install.\\n";
  3491. + if (eval \$Devel::PPPort::VERSION < $VERSION) {
  3492. + die "$0 was originally generated with Devel::PPPort $VERSION.\\n"
  3493. + . "Your Devel::PPPort is only version \$Devel::PPPort::VERSION.\\n"
  3494. + . "Please install a newer version, or --unstrip will not work.\\n";
  3495. + }
  3496. + Devel::PPPort::WriteFile(\$0);
  3497. + exit 0;
  3498. +}
  3499. +print <<END;
  3500. +
  3501. +Sorry, but this is a stripped version of \$0.
  3502. +
  3503. +To be able to use its original script and doc functionality,
  3504. +please try to regenerate this file using:
  3505. +
  3506. + \$^X \$0 --unstrip
  3507. +
  3508. +END
  3509. +/ms;
  3510. + my($pl, $c) = $self =~ /(.*^__DATA__)(.*)/ms;
  3511. + $c =~ s{
  3512. + / (?: \*[^*]*\*+(?:[^$ccs][^*]*\*+)* / | /[^\r\n]*)
  3513. + | ( "[^"\\]*(?:\\.[^"\\]*)*"
  3514. + | '[^'\\]*(?:\\.[^'\\]*)*' )
  3515. + | ($HS+) }{ defined $2 ? ' ' : ($1 || '') }gsex;
  3516. + $c =~ s!\s+$!!mg;
  3517. + $c =~ s!^$LF!!mg;
  3518. + $c =~ s!^\s*#\s*!#!mg;
  3519. + $c =~ s!^\s+!!mg;
  3520. +
  3521. + open OUT, ">$0" or die "cannot strip $0: $!\n";
  3522. + print OUT "$pl$c\n";
  3523. +
  3524. + exit 0;
  3525. +}
  3526. +
  3527. +__DATA__
  3528. +*/
  3529. +
  3530. +#ifndef _P_P_PORTABILITY_H_
  3531. +#define _P_P_PORTABILITY_H_
  3532. +
  3533. +#ifndef DPPP_NAMESPACE
  3534. +# define DPPP_NAMESPACE DPPP_
  3535. +#endif
  3536. +
  3537. +#define DPPP_CAT2(x,y) CAT2(x,y)
  3538. +#define DPPP_(name) DPPP_CAT2(DPPP_NAMESPACE, name)
  3539. +
  3540. +#ifndef PERL_REVISION
  3541. +# if !defined(__PATCHLEVEL_H_INCLUDED__) && !(defined(PATCHLEVEL) && defined(SUBVERSION))
  3542. +# define PERL_PATCHLEVEL_H_IMPLICIT
  3543. +# include <patchlevel.h>
  3544. +# endif
  3545. +# if !(defined(PERL_VERSION) || (defined(SUBVERSION) && defined(PATCHLEVEL)))
  3546. +# include <could_not_find_Perl_patchlevel.h>
  3547. +# endif
  3548. +# ifndef PERL_REVISION
  3549. +# define PERL_REVISION (5)
  3550. + /* Replace: 1 */
  3551. +# define PERL_VERSION PATCHLEVEL
  3552. +# define PERL_SUBVERSION SUBVERSION
  3553. + /* Replace PERL_PATCHLEVEL with PERL_VERSION */
  3554. + /* Replace: 0 */
  3555. +# endif
  3556. +#endif
  3557. +
  3558. +#define _dpppDEC2BCD(dec) ((((dec)/100)<<8)|((((dec)%100)/10)<<4)|((dec)%10))
  3559. +#define PERL_BCDVERSION ((_dpppDEC2BCD(PERL_REVISION)<<24)|(_dpppDEC2BCD(PERL_VERSION)<<12)|_dpppDEC2BCD(PERL_SUBVERSION))
  3560. +
  3561. +/* It is very unlikely that anyone will try to use this with Perl 6
  3562. + (or greater), but who knows.
  3563. + */
  3564. +#if PERL_REVISION != 5
  3565. +# error ppport.h only works with Perl version 5
  3566. +#endif /* PERL_REVISION != 5 */
  3567. +#ifndef dTHR
  3568. +# define dTHR dNOOP
  3569. +#endif
  3570. +#ifndef dTHX
  3571. +# define dTHX dNOOP
  3572. +#endif
  3573. +
  3574. +#ifndef dTHXa
  3575. +# define dTHXa(x) dNOOP
  3576. +#endif
  3577. +#ifndef pTHX
  3578. +# define pTHX void
  3579. +#endif
  3580. +
  3581. +#ifndef pTHX_
  3582. +# define pTHX_
  3583. +#endif
  3584. +
  3585. +#ifndef aTHX
  3586. +# define aTHX
  3587. +#endif
  3588. +
  3589. +#ifndef aTHX_
  3590. +# define aTHX_
  3591. +#endif
  3592. +
  3593. +#if (PERL_BCDVERSION < 0x5006000)
  3594. +# ifdef USE_THREADS
  3595. +# define aTHXR thr
  3596. +# define aTHXR_ thr,
  3597. +# else
  3598. +# define aTHXR
  3599. +# define aTHXR_
  3600. +# endif
  3601. +# define dTHXR dTHR
  3602. +#else
  3603. +# define aTHXR aTHX
  3604. +# define aTHXR_ aTHX_
  3605. +# define dTHXR dTHX
  3606. +#endif
  3607. +#ifndef dTHXoa
  3608. +# define dTHXoa(x) dTHXa(x)
  3609. +#endif
  3610. +
  3611. +#ifdef I_LIMITS
  3612. +# include <limits.h>
  3613. +#endif
  3614. +
  3615. +#ifndef PERL_UCHAR_MIN
  3616. +# define PERL_UCHAR_MIN ((unsigned char)0)
  3617. +#endif
  3618. +
  3619. +#ifndef PERL_UCHAR_MAX
  3620. +# ifdef UCHAR_MAX
  3621. +# define PERL_UCHAR_MAX ((unsigned char)UCHAR_MAX)
  3622. +# else
  3623. +# ifdef MAXUCHAR
  3624. +# define PERL_UCHAR_MAX ((unsigned char)MAXUCHAR)
  3625. +# else
  3626. +# define PERL_UCHAR_MAX ((unsigned char)~(unsigned)0)
  3627. +# endif
  3628. +# endif
  3629. +#endif
  3630. +
  3631. +#ifndef PERL_USHORT_MIN
  3632. +# define PERL_USHORT_MIN ((unsigned short)0)
  3633. +#endif
  3634. +
  3635. +#ifndef PERL_USHORT_MAX
  3636. +# ifdef USHORT_MAX
  3637. +# define PERL_USHORT_MAX ((unsigned short)USHORT_MAX)
  3638. +# else
  3639. +# ifdef MAXUSHORT
  3640. +# define PERL_USHORT_MAX ((unsigned short)MAXUSHORT)
  3641. +# else
  3642. +# ifdef USHRT_MAX
  3643. +# define PERL_USHORT_MAX ((unsigned short)USHRT_MAX)
  3644. +# else
  3645. +# define PERL_USHORT_MAX ((unsigned short)~(unsigned)0)
  3646. +# endif
  3647. +# endif
  3648. +# endif
  3649. +#endif
  3650. +
  3651. +#ifndef PERL_SHORT_MAX
  3652. +# ifdef SHORT_MAX
  3653. +# define PERL_SHORT_MAX ((short)SHORT_MAX)
  3654. +# else
  3655. +# ifdef MAXSHORT /* Often used in <values.h> */
  3656. +# define PERL_SHORT_MAX ((short)MAXSHORT)
  3657. +# else
  3658. +# ifdef SHRT_MAX
  3659. +# define PERL_SHORT_MAX ((short)SHRT_MAX)
  3660. +# else
  3661. +# define PERL_SHORT_MAX ((short) (PERL_USHORT_MAX >> 1))
  3662. +# endif
  3663. +# endif
  3664. +# endif
  3665. +#endif
  3666. +
  3667. +#ifndef PERL_SHORT_MIN
  3668. +# ifdef SHORT_MIN
  3669. +# define PERL_SHORT_MIN ((short)SHORT_MIN)
  3670. +# else
  3671. +# ifdef MINSHORT
  3672. +# define PERL_SHORT_MIN ((short)MINSHORT)
  3673. +# else
  3674. +# ifdef SHRT_MIN
  3675. +# define PERL_SHORT_MIN ((short)SHRT_MIN)
  3676. +# else
  3677. +# define PERL_SHORT_MIN (-PERL_SHORT_MAX - ((3 & -1) == 3))
  3678. +# endif
  3679. +# endif
  3680. +# endif
  3681. +#endif
  3682. +
  3683. +#ifndef PERL_UINT_MAX
  3684. +# ifdef UINT_MAX
  3685. +# define PERL_UINT_MAX ((unsigned int)UINT_MAX)
  3686. +# else
  3687. +# ifdef MAXUINT
  3688. +# define PERL_UINT_MAX ((unsigned int)MAXUINT)
  3689. +# else
  3690. +# define PERL_UINT_MAX (~(unsigned int)0)
  3691. +# endif
  3692. +# endif
  3693. +#endif
  3694. +
  3695. +#ifndef PERL_UINT_MIN
  3696. +# define PERL_UINT_MIN ((unsigned int)0)
  3697. +#endif
  3698. +
  3699. +#ifndef PERL_INT_MAX
  3700. +# ifdef INT_MAX
  3701. +# define PERL_INT_MAX ((int)INT_MAX)
  3702. +# else
  3703. +# ifdef MAXINT /* Often used in <values.h> */
  3704. +# define PERL_INT_MAX ((int)MAXINT)
  3705. +# else
  3706. +# define PERL_INT_MAX ((int)(PERL_UINT_MAX >> 1))
  3707. +# endif
  3708. +# endif
  3709. +#endif
  3710. +
  3711. +#ifndef PERL_INT_MIN
  3712. +# ifdef INT_MIN
  3713. +# define PERL_INT_MIN ((int)INT_MIN)
  3714. +# else
  3715. +# ifdef MININT
  3716. +# define PERL_INT_MIN ((int)MININT)
  3717. +# else
  3718. +# define PERL_INT_MIN (-PERL_INT_MAX - ((3 & -1) == 3))
  3719. +# endif
  3720. +# endif
  3721. +#endif
  3722. +
  3723. +#ifndef PERL_ULONG_MAX
  3724. +# ifdef ULONG_MAX
  3725. +# define PERL_ULONG_MAX ((unsigned long)ULONG_MAX)
  3726. +# else
  3727. +# ifdef MAXULONG
  3728. +# define PERL_ULONG_MAX ((unsigned long)MAXULONG)
  3729. +# else
  3730. +# define PERL_ULONG_MAX (~(unsigned long)0)
  3731. +# endif
  3732. +# endif
  3733. +#endif
  3734. +
  3735. +#ifndef PERL_ULONG_MIN
  3736. +# define PERL_ULONG_MIN ((unsigned long)0L)
  3737. +#endif
  3738. +
  3739. +#ifndef PERL_LONG_MAX
  3740. +# ifdef LONG_MAX
  3741. +# define PERL_LONG_MAX ((long)LONG_MAX)
  3742. +# else
  3743. +# ifdef MAXLONG
  3744. +# define PERL_LONG_MAX ((long)MAXLONG)
  3745. +# else
  3746. +# define PERL_LONG_MAX ((long) (PERL_ULONG_MAX >> 1))
  3747. +# endif
  3748. +# endif
  3749. +#endif
  3750. +
  3751. +#ifndef PERL_LONG_MIN
  3752. +# ifdef LONG_MIN
  3753. +# define PERL_LONG_MIN ((long)LONG_MIN)
  3754. +# else
  3755. +# ifdef MINLONG
  3756. +# define PERL_LONG_MIN ((long)MINLONG)
  3757. +# else
  3758. +# define PERL_LONG_MIN (-PERL_LONG_MAX - ((3 & -1) == 3))
  3759. +# endif
  3760. +# endif
  3761. +#endif
  3762. +
  3763. +#if defined(HAS_QUAD) && (defined(convex) || defined(uts))
  3764. +# ifndef PERL_UQUAD_MAX
  3765. +# ifdef ULONGLONG_MAX
  3766. +# define PERL_UQUAD_MAX ((unsigned long long)ULONGLONG_MAX)
  3767. +# else
  3768. +# ifdef MAXULONGLONG
  3769. +# define PERL_UQUAD_MAX ((unsigned long long)MAXULONGLONG)
  3770. +# else
  3771. +# define PERL_UQUAD_MAX (~(unsigned long long)0)
  3772. +# endif
  3773. +# endif
  3774. +# endif
  3775. +
  3776. +# ifndef PERL_UQUAD_MIN
  3777. +# define PERL_UQUAD_MIN ((unsigned long long)0L)
  3778. +# endif
  3779. +
  3780. +# ifndef PERL_QUAD_MAX
  3781. +# ifdef LONGLONG_MAX
  3782. +# define PERL_QUAD_MAX ((long long)LONGLONG_MAX)
  3783. +# else
  3784. +# ifdef MAXLONGLONG
  3785. +# define PERL_QUAD_MAX ((long long)MAXLONGLONG)
  3786. +# else
  3787. +# define PERL_QUAD_MAX ((long long) (PERL_UQUAD_MAX >> 1))
  3788. +# endif
  3789. +# endif
  3790. +# endif
  3791. +
  3792. +# ifndef PERL_QUAD_MIN
  3793. +# ifdef LONGLONG_MIN
  3794. +# define PERL_QUAD_MIN ((long long)LONGLONG_MIN)
  3795. +# else
  3796. +# ifdef MINLONGLONG
  3797. +# define PERL_QUAD_MIN ((long long)MINLONGLONG)
  3798. +# else
  3799. +# define PERL_QUAD_MIN (-PERL_QUAD_MAX - ((3 & -1) == 3))
  3800. +# endif
  3801. +# endif
  3802. +# endif
  3803. +#endif
  3804. +
  3805. +/* This is based on code from 5.003 perl.h */
  3806. +#ifdef HAS_QUAD
  3807. +# ifdef cray
  3808. +#ifndef IVTYPE
  3809. +# define IVTYPE int
  3810. +#endif
  3811. +
  3812. +#ifndef IV_MIN
  3813. +# define IV_MIN PERL_INT_MIN
  3814. +#endif
  3815. +
  3816. +#ifndef IV_MAX
  3817. +# define IV_MAX PERL_INT_MAX
  3818. +#endif
  3819. +
  3820. +#ifndef UV_MIN
  3821. +# define UV_MIN PERL_UINT_MIN
  3822. +#endif
  3823. +
  3824. +#ifndef UV_MAX
  3825. +# define UV_MAX PERL_UINT_MAX
  3826. +#endif
  3827. +
  3828. +# ifdef INTSIZE
  3829. +#ifndef IVSIZE
  3830. +# define IVSIZE INTSIZE
  3831. +#endif
  3832. +
  3833. +# endif
  3834. +# else
  3835. +# if defined(convex) || defined(uts)
  3836. +#ifndef IVTYPE
  3837. +# define IVTYPE long long
  3838. +#endif
  3839. +
  3840. +#ifndef IV_MIN
  3841. +# define IV_MIN PERL_QUAD_MIN
  3842. +#endif
  3843. +
  3844. +#ifndef IV_MAX
  3845. +# define IV_MAX PERL_QUAD_MAX
  3846. +#endif
  3847. +
  3848. +#ifndef UV_MIN
  3849. +# define UV_MIN PERL_UQUAD_MIN
  3850. +#endif
  3851. +
  3852. +#ifndef UV_MAX
  3853. +# define UV_MAX PERL_UQUAD_MAX
  3854. +#endif
  3855. +
  3856. +# ifdef LONGLONGSIZE
  3857. +#ifndef IVSIZE
  3858. +# define IVSIZE LONGLONGSIZE
  3859. +#endif
  3860. +
  3861. +# endif
  3862. +# else
  3863. +#ifndef IVTYPE
  3864. +# define IVTYPE long
  3865. +#endif
  3866. +
  3867. +#ifndef IV_MIN
  3868. +# define IV_MIN PERL_LONG_MIN
  3869. +#endif
  3870. +
  3871. +#ifndef IV_MAX
  3872. +# define IV_MAX PERL_LONG_MAX
  3873. +#endif
  3874. +
  3875. +#ifndef UV_MIN
  3876. +# define UV_MIN PERL_ULONG_MIN
  3877. +#endif
  3878. +
  3879. +#ifndef UV_MAX
  3880. +# define UV_MAX PERL_ULONG_MAX
  3881. +#endif
  3882. +
  3883. +# ifdef LONGSIZE
  3884. +#ifndef IVSIZE
  3885. +# define IVSIZE LONGSIZE
  3886. +#endif
  3887. +
  3888. +# endif
  3889. +# endif
  3890. +# endif
  3891. +#ifndef IVSIZE
  3892. +# define IVSIZE 8
  3893. +#endif
  3894. +
  3895. +#ifndef LONGSIZE
  3896. +# define LONGSIZE 8
  3897. +#endif
  3898. +
  3899. +#ifndef PERL_QUAD_MIN
  3900. +# define PERL_QUAD_MIN IV_MIN
  3901. +#endif
  3902. +
  3903. +#ifndef PERL_QUAD_MAX
  3904. +# define PERL_QUAD_MAX IV_MAX
  3905. +#endif
  3906. +
  3907. +#ifndef PERL_UQUAD_MIN
  3908. +# define PERL_UQUAD_MIN UV_MIN
  3909. +#endif
  3910. +
  3911. +#ifndef PERL_UQUAD_MAX
  3912. +# define PERL_UQUAD_MAX UV_MAX
  3913. +#endif
  3914. +
  3915. +#else
  3916. +#ifndef IVTYPE
  3917. +# define IVTYPE long
  3918. +#endif
  3919. +
  3920. +#ifndef LONGSIZE
  3921. +# define LONGSIZE 4
  3922. +#endif
  3923. +
  3924. +#ifndef IV_MIN
  3925. +# define IV_MIN PERL_LONG_MIN
  3926. +#endif
  3927. +
  3928. +#ifndef IV_MAX
  3929. +# define IV_MAX PERL_LONG_MAX
  3930. +#endif
  3931. +
  3932. +#ifndef UV_MIN
  3933. +# define UV_MIN PERL_ULONG_MIN
  3934. +#endif
  3935. +
  3936. +#ifndef UV_MAX
  3937. +# define UV_MAX PERL_ULONG_MAX
  3938. +#endif
  3939. +
  3940. +#endif
  3941. +
  3942. +#ifndef IVSIZE
  3943. +# ifdef LONGSIZE
  3944. +# define IVSIZE LONGSIZE
  3945. +# else
  3946. +# define IVSIZE 4 /* A bold guess, but the best we can make. */
  3947. +# endif
  3948. +#endif
  3949. +#ifndef UVTYPE
  3950. +# define UVTYPE unsigned IVTYPE
  3951. +#endif
  3952. +
  3953. +#ifndef UVSIZE
  3954. +# define UVSIZE IVSIZE
  3955. +#endif
  3956. +#ifndef sv_setuv
  3957. +# define sv_setuv(sv, uv) \
  3958. + STMT_START { \
  3959. + UV TeMpUv = uv; \
  3960. + if (TeMpUv <= IV_MAX) \
  3961. + sv_setiv(sv, TeMpUv); \
  3962. + else \
  3963. + sv_setnv(sv, (double)TeMpUv); \
  3964. + } STMT_END
  3965. +#endif
  3966. +#ifndef newSVuv
  3967. +# define newSVuv(uv) ((uv) <= IV_MAX ? newSViv((IV)uv) : newSVnv((NV)uv))
  3968. +#endif
  3969. +#ifndef sv_2uv
  3970. +# define sv_2uv(sv) ((PL_Sv = (sv)), (UV) (SvNOK(PL_Sv) ? SvNV(PL_Sv) : sv_2nv(PL_Sv)))
  3971. +#endif
  3972. +
  3973. +#ifndef SvUVX
  3974. +# define SvUVX(sv) ((UV)SvIVX(sv))
  3975. +#endif
  3976. +
  3977. +#ifndef SvUVXx
  3978. +# define SvUVXx(sv) SvUVX(sv)
  3979. +#endif
  3980. +
  3981. +#ifndef SvUV
  3982. +# define SvUV(sv) (SvIOK(sv) ? SvUVX(sv) : sv_2uv(sv))
  3983. +#endif
  3984. +
  3985. +#ifndef SvUVx
  3986. +# define SvUVx(sv) ((PL_Sv = (sv)), SvUV(PL_Sv))
  3987. +#endif
  3988. +
  3989. +/* Hint: sv_uv
  3990. + * Always use the SvUVx() macro instead of sv_uv().
  3991. + */
  3992. +#ifndef sv_uv
  3993. +# define sv_uv(sv) SvUVx(sv)
  3994. +#endif
  3995. +
  3996. +#if !defined(SvUOK) && defined(SvIOK_UV)
  3997. +# define SvUOK(sv) SvIOK_UV(sv)
  3998. +#endif
  3999. +#ifndef XST_mUV
  4000. +# define XST_mUV(i,v) (ST(i) = sv_2mortal(newSVuv(v)) )
  4001. +#endif
  4002. +
  4003. +#ifndef XSRETURN_UV
  4004. +# define XSRETURN_UV(v) STMT_START { XST_mUV(0,v); XSRETURN(1); } STMT_END
  4005. +#endif
  4006. +#ifndef PUSHu
  4007. +# define PUSHu(u) STMT_START { sv_setuv(TARG, (UV)(u)); PUSHTARG; } STMT_END
  4008. +#endif
  4009. +
  4010. +#ifndef XPUSHu
  4011. +# define XPUSHu(u) STMT_START { sv_setuv(TARG, (UV)(u)); XPUSHTARG; } STMT_END
  4012. +#endif
  4013. +
  4014. +#ifdef HAS_MEMCMP
  4015. +#ifndef memNE
  4016. +# define memNE(s1,s2,l) (memcmp(s1,s2,l))
  4017. +#endif
  4018. +
  4019. +#ifndef memEQ
  4020. +# define memEQ(s1,s2,l) (!memcmp(s1,s2,l))
  4021. +#endif
  4022. +
  4023. +#else
  4024. +#ifndef memNE
  4025. +# define memNE(s1,s2,l) (bcmp(s1,s2,l))
  4026. +#endif
  4027. +
  4028. +#ifndef memEQ
  4029. +# define memEQ(s1,s2,l) (!bcmp(s1,s2,l))
  4030. +#endif
  4031. +
  4032. +#endif
  4033. +#ifndef memEQs
  4034. +# define memEQs(s1, l, s2) \
  4035. + (sizeof(s2)-1 == l && memEQ(s1, (s2 ""), (sizeof(s2)-1)))
  4036. +#endif
  4037. +
  4038. +#ifndef memNEs
  4039. +# define memNEs(s1, l, s2) !memEQs(s1, l, s2)
  4040. +#endif
  4041. +#ifndef MoveD
  4042. +# define MoveD(s,d,n,t) memmove((char*)(d),(char*)(s), (n) * sizeof(t))
  4043. +#endif
  4044. +
  4045. +#ifndef CopyD
  4046. +# define CopyD(s,d,n,t) memcpy((char*)(d),(char*)(s), (n) * sizeof(t))
  4047. +#endif
  4048. +
  4049. +#ifdef HAS_MEMSET
  4050. +#ifndef ZeroD
  4051. +# define ZeroD(d,n,t) memzero((char*)(d), (n) * sizeof(t))
  4052. +#endif
  4053. +
  4054. +#else
  4055. +#ifndef ZeroD
  4056. +# define ZeroD(d,n,t) ((void)memzero((char*)(d), (n) * sizeof(t)), d)
  4057. +#endif
  4058. +
  4059. +#endif
  4060. +#ifndef PoisonWith
  4061. +# define PoisonWith(d,n,t,b) (void)memset((char*)(d), (U8)(b), (n) * sizeof(t))
  4062. +#endif
  4063. +
  4064. +#ifndef PoisonNew
  4065. +# define PoisonNew(d,n,t) PoisonWith(d,n,t,0xAB)
  4066. +#endif
  4067. +
  4068. +#ifndef PoisonFree
  4069. +# define PoisonFree(d,n,t) PoisonWith(d,n,t,0xEF)
  4070. +#endif
  4071. +
  4072. +#ifndef Poison
  4073. +# define Poison(d,n,t) PoisonFree(d,n,t)
  4074. +#endif
  4075. +#ifndef Newx
  4076. +# define Newx(v,n,t) New(0,v,n,t)
  4077. +#endif
  4078. +
  4079. +#ifndef Newxc
  4080. +# define Newxc(v,n,t,c) Newc(0,v,n,t,c)
  4081. +#endif
  4082. +
  4083. +#ifndef Newxz
  4084. +# define Newxz(v,n,t) Newz(0,v,n,t)
  4085. +#endif
  4086. +
  4087. +#ifndef PERL_UNUSED_DECL
  4088. +# ifdef HASATTRIBUTE
  4089. +# if (defined(__GNUC__) && defined(__cplusplus)) || defined(__INTEL_COMPILER)
  4090. +# define PERL_UNUSED_DECL
  4091. +# else
  4092. +# define PERL_UNUSED_DECL __attribute__((unused))
  4093. +# endif
  4094. +# else
  4095. +# define PERL_UNUSED_DECL
  4096. +# endif
  4097. +#endif
  4098. +
  4099. +#ifndef PERL_UNUSED_ARG
  4100. +# if defined(lint) && defined(S_SPLINT_S) /* www.splint.org */
  4101. +# include <note.h>
  4102. +# define PERL_UNUSED_ARG(x) NOTE(ARGUNUSED(x))
  4103. +# else
  4104. +# define PERL_UNUSED_ARG(x) ((void)x)
  4105. +# endif
  4106. +#endif
  4107. +
  4108. +#ifndef PERL_UNUSED_VAR
  4109. +# define PERL_UNUSED_VAR(x) ((void)x)
  4110. +#endif
  4111. +
  4112. +#ifndef PERL_UNUSED_CONTEXT
  4113. +# ifdef USE_ITHREADS
  4114. +# define PERL_UNUSED_CONTEXT PERL_UNUSED_ARG(my_perl)
  4115. +# else
  4116. +# define PERL_UNUSED_CONTEXT
  4117. +# endif
  4118. +#endif
  4119. +#ifndef NOOP
  4120. +# define NOOP /*EMPTY*/(void)0
  4121. +#endif
  4122. +
  4123. +#ifndef dNOOP
  4124. +# define dNOOP extern int /*@unused@*/ Perl___notused PERL_UNUSED_DECL
  4125. +#endif
  4126. +
  4127. +#ifndef NVTYPE
  4128. +# if defined(USE_LONG_DOUBLE) && defined(HAS_LONG_DOUBLE)
  4129. +# define NVTYPE long double
  4130. +# else
  4131. +# define NVTYPE double
  4132. +# endif
  4133. +typedef NVTYPE NV;
  4134. +#endif
  4135. +
  4136. +#ifndef INT2PTR
  4137. +# if (IVSIZE == PTRSIZE) && (UVSIZE == PTRSIZE)
  4138. +# define PTRV UV
  4139. +# define INT2PTR(any,d) (any)(d)
  4140. +# else
  4141. +# if PTRSIZE == LONGSIZE
  4142. +# define PTRV unsigned long
  4143. +# else
  4144. +# define PTRV unsigned
  4145. +# endif
  4146. +# define INT2PTR(any,d) (any)(PTRV)(d)
  4147. +# endif
  4148. +#endif
  4149. +
  4150. +#ifndef PTR2ul
  4151. +# if PTRSIZE == LONGSIZE
  4152. +# define PTR2ul(p) (unsigned long)(p)
  4153. +# else
  4154. +# define PTR2ul(p) INT2PTR(unsigned long,p)
  4155. +# endif
  4156. +#endif
  4157. +#ifndef PTR2nat
  4158. +# define PTR2nat(p) (PTRV)(p)
  4159. +#endif
  4160. +
  4161. +#ifndef NUM2PTR
  4162. +# define NUM2PTR(any,d) (any)PTR2nat(d)
  4163. +#endif
  4164. +
  4165. +#ifndef PTR2IV
  4166. +# define PTR2IV(p) INT2PTR(IV,p)
  4167. +#endif
  4168. +
  4169. +#ifndef PTR2UV
  4170. +# define PTR2UV(p) INT2PTR(UV,p)
  4171. +#endif
  4172. +
  4173. +#ifndef PTR2NV
  4174. +# define PTR2NV(p) NUM2PTR(NV,p)
  4175. +#endif
  4176. +
  4177. +#undef START_EXTERN_C
  4178. +#undef END_EXTERN_C
  4179. +#undef EXTERN_C
  4180. +#ifdef __cplusplus
  4181. +# define START_EXTERN_C extern "C" {
  4182. +# define END_EXTERN_C }
  4183. +# define EXTERN_C extern "C"
  4184. +#else
  4185. +# define START_EXTERN_C
  4186. +# define END_EXTERN_C
  4187. +# define EXTERN_C extern
  4188. +#endif
  4189. +
  4190. +#if defined(PERL_GCC_PEDANTIC)
  4191. +# ifndef PERL_GCC_BRACE_GROUPS_FORBIDDEN
  4192. +# define PERL_GCC_BRACE_GROUPS_FORBIDDEN
  4193. +# endif
  4194. +#endif
  4195. +
  4196. +#if defined(__GNUC__) && !defined(PERL_GCC_BRACE_GROUPS_FORBIDDEN) && !defined(__cplusplus)
  4197. +# ifndef PERL_USE_GCC_BRACE_GROUPS
  4198. +# define PERL_USE_GCC_BRACE_GROUPS
  4199. +# endif
  4200. +#endif
  4201. +
  4202. +#undef STMT_START
  4203. +#undef STMT_END
  4204. +#ifdef PERL_USE_GCC_BRACE_GROUPS
  4205. +# define STMT_START (void)( /* gcc supports ``({ STATEMENTS; })'' */
  4206. +# define STMT_END )
  4207. +#else
  4208. +# if defined(VOIDFLAGS) && (VOIDFLAGS) && (defined(sun) || defined(__sun__)) && !defined(__GNUC__)
  4209. +# define STMT_START if (1)
  4210. +# define STMT_END else (void)0
  4211. +# else
  4212. +# define STMT_START do
  4213. +# define STMT_END while (0)
  4214. +# endif
  4215. +#endif
  4216. +#ifndef boolSV
  4217. +# define boolSV(b) ((b) ? &PL_sv_yes : &PL_sv_no)
  4218. +#endif
  4219. +
  4220. +/* DEFSV appears first in 5.004_56 */
  4221. +#ifndef DEFSV
  4222. +# define DEFSV GvSV(PL_defgv)
  4223. +#endif
  4224. +
  4225. +#ifndef SAVE_DEFSV
  4226. +# define SAVE_DEFSV SAVESPTR(GvSV(PL_defgv))
  4227. +#endif
  4228. +
  4229. +#ifndef DEFSV_set
  4230. +# define DEFSV_set(sv) (DEFSV = (sv))
  4231. +#endif
  4232. +
  4233. +/* Older perls (<=5.003) lack AvFILLp */
  4234. +#ifndef AvFILLp
  4235. +# define AvFILLp AvFILL
  4236. +#endif
  4237. +#ifndef ERRSV
  4238. +# define ERRSV get_sv("@",FALSE)
  4239. +#endif
  4240. +
  4241. +/* Hint: gv_stashpvn
  4242. + * This function's backport doesn't support the length parameter, but
  4243. + * rather ignores it. Portability can only be ensured if the length
  4244. + * parameter is used for speed reasons, but the length can always be
  4245. + * correctly computed from the string argument.
  4246. + */
  4247. +#ifndef gv_stashpvn
  4248. +# define gv_stashpvn(str,len,create) gv_stashpv(str,create)
  4249. +#endif
  4250. +
  4251. +/* Replace: 1 */
  4252. +#ifndef get_cv
  4253. +# define get_cv perl_get_cv
  4254. +#endif
  4255. +
  4256. +#ifndef get_sv
  4257. +# define get_sv perl_get_sv
  4258. +#endif
  4259. +
  4260. +#ifndef get_av
  4261. +# define get_av perl_get_av
  4262. +#endif
  4263. +
  4264. +#ifndef get_hv
  4265. +# define get_hv perl_get_hv
  4266. +#endif
  4267. +
  4268. +/* Replace: 0 */
  4269. +#ifndef dUNDERBAR
  4270. +# define dUNDERBAR dNOOP
  4271. +#endif
  4272. +
  4273. +#ifndef UNDERBAR
  4274. +# define UNDERBAR DEFSV
  4275. +#endif
  4276. +#ifndef dAX
  4277. +# define dAX I32 ax = MARK - PL_stack_base + 1
  4278. +#endif
  4279. +
  4280. +#ifndef dITEMS
  4281. +# define dITEMS I32 items = SP - MARK
  4282. +#endif
  4283. +#ifndef dXSTARG
  4284. +# define dXSTARG SV * targ = sv_newmortal()
  4285. +#endif
  4286. +#ifndef dAXMARK
  4287. +# define dAXMARK I32 ax = POPMARK; \
  4288. + register SV ** const mark = PL_stack_base + ax++
  4289. +#endif
  4290. +#ifndef XSprePUSH
  4291. +# define XSprePUSH (sp = PL_stack_base + ax - 1)
  4292. +#endif
  4293. +
  4294. +#if (PERL_BCDVERSION < 0x5005000)
  4295. +# undef XSRETURN
  4296. +# define XSRETURN(off) \
  4297. + STMT_START { \
  4298. + PL_stack_sp = PL_stack_base + ax + ((off) - 1); \
  4299. + return; \
  4300. + } STMT_END
  4301. +#endif
  4302. +#ifndef XSPROTO
  4303. +# define XSPROTO(name) void name(pTHX_ CV* cv)
  4304. +#endif
  4305. +
  4306. +#ifndef SVfARG
  4307. +# define SVfARG(p) ((void*)(p))
  4308. +#endif
  4309. +#ifndef PERL_ABS
  4310. +# define PERL_ABS(x) ((x) < 0 ? -(x) : (x))
  4311. +#endif
  4312. +#ifndef dVAR
  4313. +# define dVAR dNOOP
  4314. +#endif
  4315. +#ifndef SVf
  4316. +# define SVf "_"
  4317. +#endif
  4318. +#ifndef UTF8_MAXBYTES
  4319. +# define UTF8_MAXBYTES UTF8_MAXLEN
  4320. +#endif
  4321. +#ifndef CPERLscope
  4322. +# define CPERLscope(x) x
  4323. +#endif
  4324. +#ifndef PERL_HASH
  4325. +# define PERL_HASH(hash,str,len) \
  4326. + STMT_START { \
  4327. + const char *s_PeRlHaSh = str; \
  4328. + I32 i_PeRlHaSh = len; \
  4329. + U32 hash_PeRlHaSh = 0; \
  4330. + while (i_PeRlHaSh--) \
  4331. + hash_PeRlHaSh = hash_PeRlHaSh * 33 + *s_PeRlHaSh++; \
  4332. + (hash) = hash_PeRlHaSh; \
  4333. + } STMT_END
  4334. +#endif
  4335. +
  4336. +#ifndef PERLIO_FUNCS_DECL
  4337. +# ifdef PERLIO_FUNCS_CONST
  4338. +# define PERLIO_FUNCS_DECL(funcs) const PerlIO_funcs funcs
  4339. +# define PERLIO_FUNCS_CAST(funcs) (PerlIO_funcs*)(funcs)
  4340. +# else
  4341. +# define PERLIO_FUNCS_DECL(funcs) PerlIO_funcs funcs
  4342. +# define PERLIO_FUNCS_CAST(funcs) (funcs)
  4343. +# endif
  4344. +#endif
  4345. +
  4346. +/* provide these typedefs for older perls */
  4347. +#if (PERL_BCDVERSION < 0x5009003)
  4348. +
  4349. +# ifdef ARGSproto
  4350. +typedef OP* (CPERLscope(*Perl_ppaddr_t))(ARGSproto);
  4351. +# else
  4352. +typedef OP* (CPERLscope(*Perl_ppaddr_t))(pTHX);
  4353. +# endif
  4354. +
  4355. +typedef OP* (CPERLscope(*Perl_check_t)) (pTHX_ OP*);
  4356. +
  4357. +#endif
  4358. +#ifndef isPSXSPC
  4359. +# define isPSXSPC(c) (isSPACE(c) || (c) == '\v')
  4360. +#endif
  4361. +
  4362. +#ifndef isBLANK
  4363. +# define isBLANK(c) ((c) == ' ' || (c) == '\t')
  4364. +#endif
  4365. +
  4366. +#ifdef EBCDIC
  4367. +#ifndef isALNUMC
  4368. +# define isALNUMC(c) isalnum(c)
  4369. +#endif
  4370. +
  4371. +#ifndef isASCII
  4372. +# define isASCII(c) isascii(c)
  4373. +#endif
  4374. +
  4375. +#ifndef isCNTRL
  4376. +# define isCNTRL(c) iscntrl(c)
  4377. +#endif
  4378. +
  4379. +#ifndef isGRAPH
  4380. +# define isGRAPH(c) isgraph(c)
  4381. +#endif
  4382. +
  4383. +#ifndef isPRINT
  4384. +# define isPRINT(c) isprint(c)
  4385. +#endif
  4386. +
  4387. +#ifndef isPUNCT
  4388. +# define isPUNCT(c) ispunct(c)
  4389. +#endif
  4390. +
  4391. +#ifndef isXDIGIT
  4392. +# define isXDIGIT(c) isxdigit(c)
  4393. +#endif
  4394. +
  4395. +#else
  4396. +# if (PERL_BCDVERSION < 0x5010000)
  4397. +/* Hint: isPRINT
  4398. + * The implementation in older perl versions includes all of the
  4399. + * isSPACE() characters, which is wrong. The version provided by
  4400. + * Devel::PPPort always overrides a present buggy version.
  4401. + */
  4402. +# undef isPRINT
  4403. +# endif
  4404. +
  4405. +#ifdef HAS_QUAD
  4406. +# define WIDEST_UTYPE U64TYPE
  4407. +#else
  4408. +# define WIDEST_UTYPE U32
  4409. +#endif
  4410. +#ifndef isALNUMC
  4411. +# define isALNUMC(c) (isALPHA(c) || isDIGIT(c))
  4412. +#endif
  4413. +
  4414. +#ifndef isASCII
  4415. +# define isASCII(c) ((WIDEST_UTYPE) (c) <= 127)
  4416. +#endif
  4417. +
  4418. +#ifndef isCNTRL
  4419. +# define isCNTRL(c) ((WIDEST_UTYPE) (c) < ' ' || (c) == 127)
  4420. +#endif
  4421. +
  4422. +#ifndef isGRAPH
  4423. +# define isGRAPH(c) (isALNUM(c) || isPUNCT(c))
  4424. +#endif
  4425. +
  4426. +#ifndef isPRINT
  4427. +# define isPRINT(c) (((c) >= 32 && (c) < 127))
  4428. +#endif
  4429. +
  4430. +#ifndef isPUNCT
  4431. +# define isPUNCT(c) (((c) >= 33 && (c) <= 47) || ((c) >= 58 && (c) <= 64) || ((c) >= 91 && (c) <= 96) || ((c) >= 123 && (c) <= 126))
  4432. +#endif
  4433. +
  4434. +#ifndef isXDIGIT
  4435. +# define isXDIGIT(c) (isDIGIT(c) || ((c) >= 'a' && (c) <= 'f') || ((c) >= 'A' && (c) <= 'F'))
  4436. +#endif
  4437. +
  4438. +#endif
  4439. +
  4440. +#ifndef PERL_SIGNALS_UNSAFE_FLAG
  4441. +
  4442. +#define PERL_SIGNALS_UNSAFE_FLAG 0x0001
  4443. +
  4444. +#if (PERL_BCDVERSION < 0x5008000)
  4445. +# define D_PPP_PERL_SIGNALS_INIT PERL_SIGNALS_UNSAFE_FLAG
  4446. +#else
  4447. +# define D_PPP_PERL_SIGNALS_INIT 0
  4448. +#endif
  4449. +
  4450. +#if defined(NEED_PL_signals)
  4451. +static U32 DPPP_(my_PL_signals) = D_PPP_PERL_SIGNALS_INIT;
  4452. +#elif defined(NEED_PL_signals_GLOBAL)
  4453. +U32 DPPP_(my_PL_signals) = D_PPP_PERL_SIGNALS_INIT;
  4454. +#else
  4455. +extern U32 DPPP_(my_PL_signals);
  4456. +#endif
  4457. +#define PL_signals DPPP_(my_PL_signals)
  4458. +
  4459. +#endif
  4460. +
  4461. +/* Hint: PL_ppaddr
  4462. + * Calling an op via PL_ppaddr requires passing a context argument
  4463. + * for threaded builds. Since the context argument is different for
  4464. + * 5.005 perls, you can use aTHXR (supplied by ppport.h), which will
  4465. + * automatically be defined as the correct argument.
  4466. + */
  4467. +
  4468. +#if (PERL_BCDVERSION <= 0x5005005)
  4469. +/* Replace: 1 */
  4470. +# define PL_ppaddr ppaddr
  4471. +# define PL_no_modify no_modify
  4472. +/* Replace: 0 */
  4473. +#endif
  4474. +
  4475. +#if (PERL_BCDVERSION <= 0x5004005)
  4476. +/* Replace: 1 */
  4477. +# define PL_DBsignal DBsignal
  4478. +# define PL_DBsingle DBsingle
  4479. +# define PL_DBsub DBsub
  4480. +# define PL_DBtrace DBtrace
  4481. +# define PL_Sv Sv
  4482. +# define PL_bufend bufend
  4483. +# define PL_bufptr bufptr
  4484. +# define PL_compiling compiling
  4485. +# define PL_copline copline
  4486. +# define PL_curcop curcop
  4487. +# define PL_curstash curstash
  4488. +# define PL_debstash debstash
  4489. +# define PL_defgv defgv
  4490. +# define PL_diehook diehook
  4491. +# define PL_dirty dirty
  4492. +# define PL_dowarn dowarn
  4493. +# define PL_errgv errgv
  4494. +# define PL_error_count error_count
  4495. +# define PL_expect expect
  4496. +# define PL_hexdigit hexdigit
  4497. +# define PL_hints hints
  4498. +# define PL_in_my in_my
  4499. +# define PL_laststatval laststatval
  4500. +# define PL_lex_state lex_state
  4501. +# define PL_lex_stuff lex_stuff
  4502. +# define PL_linestr linestr
  4503. +# define PL_na na
  4504. +# define PL_perl_destruct_level perl_destruct_level
  4505. +# define PL_perldb perldb
  4506. +# define PL_rsfp_filters rsfp_filters
  4507. +# define PL_rsfp rsfp
  4508. +# define PL_stack_base stack_base
  4509. +# define PL_stack_sp stack_sp
  4510. +# define PL_statcache statcache
  4511. +# define PL_stdingv stdingv
  4512. +# define PL_sv_arenaroot sv_arenaroot
  4513. +# define PL_sv_no sv_no
  4514. +# define PL_sv_undef sv_undef
  4515. +# define PL_sv_yes sv_yes
  4516. +# define PL_tainted tainted
  4517. +# define PL_tainting tainting
  4518. +# define PL_tokenbuf tokenbuf
  4519. +/* Replace: 0 */
  4520. +#endif
  4521. +
  4522. +/* Warning: PL_parser
  4523. + * For perl versions earlier than 5.9.5, this is an always
  4524. + * non-NULL dummy. Also, it cannot be dereferenced. Don't
  4525. + * use it if you can avoid is and unless you absolutely know
  4526. + * what you're doing.
  4527. + * If you always check that PL_parser is non-NULL, you can
  4528. + * define DPPP_PL_parser_NO_DUMMY to avoid the creation of
  4529. + * a dummy parser structure.
  4530. + */
  4531. +
  4532. +#if (PERL_BCDVERSION >= 0x5009005)
  4533. +# ifdef DPPP_PL_parser_NO_DUMMY
  4534. +# define D_PPP_my_PL_parser_var(var) ((PL_parser ? PL_parser : \
  4535. + (croak("panic: PL_parser == NULL in %s:%d", \
  4536. + __FILE__, __LINE__), (yy_parser *) NULL))->var)
  4537. +# else
  4538. +# ifdef DPPP_PL_parser_NO_DUMMY_WARNING
  4539. +# define D_PPP_parser_dummy_warning(var)
  4540. +# else
  4541. +# define D_PPP_parser_dummy_warning(var) \
  4542. + warn("warning: dummy PL_" #var " used in %s:%d", __FILE__, __LINE__),
  4543. +# endif
  4544. +# define D_PPP_my_PL_parser_var(var) ((PL_parser ? PL_parser : \
  4545. + (D_PPP_parser_dummy_warning(var) &DPPP_(dummy_PL_parser)))->var)
  4546. +#if defined(NEED_PL_parser)
  4547. +static yy_parser DPPP_(dummy_PL_parser);
  4548. +#elif defined(NEED_PL_parser_GLOBAL)
  4549. +yy_parser DPPP_(dummy_PL_parser);
  4550. +#else
  4551. +extern yy_parser DPPP_(dummy_PL_parser);
  4552. +#endif
  4553. +
  4554. +# endif
  4555. +
  4556. +/* PL_expect, PL_copline, PL_rsfp, PL_rsfp_filters, PL_linestr, PL_bufptr, PL_bufend, PL_lex_state, PL_lex_stuff, PL_tokenbuf depends on PL_parser */
  4557. +/* Warning: PL_expect, PL_copline, PL_rsfp, PL_rsfp_filters, PL_linestr, PL_bufptr, PL_bufend, PL_lex_state, PL_lex_stuff, PL_tokenbuf
  4558. + * Do not use this variable unless you know exactly what you're
  4559. + * doint. It is internal to the perl parser and may change or even
  4560. + * be removed in the future. As of perl 5.9.5, you have to check
  4561. + * for (PL_parser != NULL) for this variable to have any effect.
  4562. + * An always non-NULL PL_parser dummy is provided for earlier
  4563. + * perl versions.
  4564. + * If PL_parser is NULL when you try to access this variable, a
  4565. + * dummy is being accessed instead and a warning is issued unless
  4566. + * you define DPPP_PL_parser_NO_DUMMY_WARNING.
  4567. + * If DPPP_PL_parser_NO_DUMMY is defined, the code trying to access
  4568. + * this variable will croak with a panic message.
  4569. + */
  4570. +
  4571. +# define PL_expect D_PPP_my_PL_parser_var(expect)
  4572. +# define PL_copline D_PPP_my_PL_parser_var(copline)
  4573. +# define PL_rsfp D_PPP_my_PL_parser_var(rsfp)
  4574. +# define PL_rsfp_filters D_PPP_my_PL_parser_var(rsfp_filters)
  4575. +# define PL_linestr D_PPP_my_PL_parser_var(linestr)
  4576. +# define PL_bufptr D_PPP_my_PL_parser_var(bufptr)
  4577. +# define PL_bufend D_PPP_my_PL_parser_var(bufend)
  4578. +# define PL_lex_state D_PPP_my_PL_parser_var(lex_state)
  4579. +# define PL_lex_stuff D_PPP_my_PL_parser_var(lex_stuff)
  4580. +# define PL_tokenbuf D_PPP_my_PL_parser_var(tokenbuf)
  4581. +# define PL_in_my D_PPP_my_PL_parser_var(in_my)
  4582. +# define PL_in_my_stash D_PPP_my_PL_parser_var(in_my_stash)
  4583. +# define PL_error_count D_PPP_my_PL_parser_var(error_count)
  4584. +
  4585. +
  4586. +#else
  4587. +
  4588. +/* ensure that PL_parser != NULL and cannot be dereferenced */
  4589. +# define PL_parser ((void *) 1)
  4590. +
  4591. +#endif
  4592. +#ifndef mPUSHs
  4593. +# define mPUSHs(s) PUSHs(sv_2mortal(s))
  4594. +#endif
  4595. +
  4596. +#ifndef PUSHmortal
  4597. +# define PUSHmortal PUSHs(sv_newmortal())
  4598. +#endif
  4599. +
  4600. +#ifndef mPUSHp
  4601. +# define mPUSHp(p,l) sv_setpvn(PUSHmortal, (p), (l))
  4602. +#endif
  4603. +
  4604. +#ifndef mPUSHn
  4605. +# define mPUSHn(n) sv_setnv(PUSHmortal, (NV)(n))
  4606. +#endif
  4607. +
  4608. +#ifndef mPUSHi
  4609. +# define mPUSHi(i) sv_setiv(PUSHmortal, (IV)(i))
  4610. +#endif
  4611. +
  4612. +#ifndef mPUSHu
  4613. +# define mPUSHu(u) sv_setuv(PUSHmortal, (UV)(u))
  4614. +#endif
  4615. +#ifndef mXPUSHs
  4616. +# define mXPUSHs(s) XPUSHs(sv_2mortal(s))
  4617. +#endif
  4618. +
  4619. +#ifndef XPUSHmortal
  4620. +# define XPUSHmortal XPUSHs(sv_newmortal())
  4621. +#endif
  4622. +
  4623. +#ifndef mXPUSHp
  4624. +# define mXPUSHp(p,l) STMT_START { EXTEND(sp,1); sv_setpvn(PUSHmortal, (p), (l)); } STMT_END
  4625. +#endif
  4626. +
  4627. +#ifndef mXPUSHn
  4628. +# define mXPUSHn(n) STMT_START { EXTEND(sp,1); sv_setnv(PUSHmortal, (NV)(n)); } STMT_END
  4629. +#endif
  4630. +
  4631. +#ifndef mXPUSHi
  4632. +# define mXPUSHi(i) STMT_START { EXTEND(sp,1); sv_setiv(PUSHmortal, (IV)(i)); } STMT_END
  4633. +#endif
  4634. +
  4635. +#ifndef mXPUSHu
  4636. +# define mXPUSHu(u) STMT_START { EXTEND(sp,1); sv_setuv(PUSHmortal, (UV)(u)); } STMT_END
  4637. +#endif
  4638. +
  4639. +/* Replace: 1 */
  4640. +#ifndef call_sv
  4641. +# define call_sv perl_call_sv
  4642. +#endif
  4643. +
  4644. +#ifndef call_pv
  4645. +# define call_pv perl_call_pv
  4646. +#endif
  4647. +
  4648. +#ifndef call_argv
  4649. +# define call_argv perl_call_argv
  4650. +#endif
  4651. +
  4652. +#ifndef call_method
  4653. +# define call_method perl_call_method
  4654. +#endif
  4655. +#ifndef eval_sv
  4656. +# define eval_sv perl_eval_sv
  4657. +#endif
  4658. +
  4659. +/* Replace: 0 */
  4660. +#ifndef PERL_LOADMOD_DENY
  4661. +# define PERL_LOADMOD_DENY 0x1
  4662. +#endif
  4663. +
  4664. +#ifndef PERL_LOADMOD_NOIMPORT
  4665. +# define PERL_LOADMOD_NOIMPORT 0x2
  4666. +#endif
  4667. +
  4668. +#ifndef PERL_LOADMOD_IMPORT_OPS
  4669. +# define PERL_LOADMOD_IMPORT_OPS 0x4
  4670. +#endif
  4671. +
  4672. +#ifndef G_METHOD
  4673. +# define G_METHOD 64
  4674. +# ifdef call_sv
  4675. +# undef call_sv
  4676. +# endif
  4677. +# if (PERL_BCDVERSION < 0x5006000)
  4678. +# define call_sv(sv, flags) ((flags) & G_METHOD ? perl_call_method((char *) SvPV_nolen_const(sv), \
  4679. + (flags) & ~G_METHOD) : perl_call_sv(sv, flags))
  4680. +# else
  4681. +# define call_sv(sv, flags) ((flags) & G_METHOD ? Perl_call_method(aTHX_ (char *) SvPV_nolen_const(sv), \
  4682. + (flags) & ~G_METHOD) : Perl_call_sv(aTHX_ sv, flags))
  4683. +# endif
  4684. +#endif
  4685. +
  4686. +/* Replace perl_eval_pv with eval_pv */
  4687. +
  4688. +#ifndef eval_pv
  4689. +#if defined(NEED_eval_pv)
  4690. +static SV* DPPP_(my_eval_pv)(char *p, I32 croak_on_error);
  4691. +static
  4692. +#else
  4693. +extern SV* DPPP_(my_eval_pv)(char *p, I32 croak_on_error);
  4694. +#endif
  4695. +
  4696. +#ifdef eval_pv
  4697. +# undef eval_pv
  4698. +#endif
  4699. +#define eval_pv(a,b) DPPP_(my_eval_pv)(aTHX_ a,b)
  4700. +#define Perl_eval_pv DPPP_(my_eval_pv)
  4701. +
  4702. +#if defined(NEED_eval_pv) || defined(NEED_eval_pv_GLOBAL)
  4703. +
  4704. +SV*
  4705. +DPPP_(my_eval_pv)(char *p, I32 croak_on_error)
  4706. +{
  4707. + dSP;
  4708. + SV* sv = newSVpv(p, 0);
  4709. +
  4710. + PUSHMARK(sp);
  4711. + eval_sv(sv, G_SCALAR);
  4712. + SvREFCNT_dec(sv);
  4713. +
  4714. + SPAGAIN;
  4715. + sv = POPs;
  4716. + PUTBACK;
  4717. +
  4718. + if (croak_on_error && SvTRUE(GvSV(errgv)))
  4719. + croak(SvPVx(GvSV(errgv), na));
  4720. +
  4721. + return sv;
  4722. +}
  4723. +
  4724. +#endif
  4725. +#endif
  4726. +
  4727. +#ifndef vload_module
  4728. +#if defined(NEED_vload_module)
  4729. +static void DPPP_(my_vload_module)(U32 flags, SV *name, SV *ver, va_list *args);
  4730. +static
  4731. +#else
  4732. +extern void DPPP_(my_vload_module)(U32 flags, SV *name, SV *ver, va_list *args);
  4733. +#endif
  4734. +
  4735. +#ifdef vload_module
  4736. +# undef vload_module
  4737. +#endif
  4738. +#define vload_module(a,b,c,d) DPPP_(my_vload_module)(aTHX_ a,b,c,d)
  4739. +#define Perl_vload_module DPPP_(my_vload_module)
  4740. +
  4741. +#if defined(NEED_vload_module) || defined(NEED_vload_module_GLOBAL)
  4742. +
  4743. +void
  4744. +DPPP_(my_vload_module)(U32 flags, SV *name, SV *ver, va_list *args)
  4745. +{
  4746. + dTHR;
  4747. + dVAR;
  4748. + OP *veop, *imop;
  4749. +
  4750. + OP * const modname = newSVOP(OP_CONST, 0, name);
  4751. + /* 5.005 has a somewhat hacky force_normal that doesn't croak on
  4752. + SvREADONLY() if PL_compling is true. Current perls take care in
  4753. + ck_require() to correctly turn off SvREADONLY before calling
  4754. + force_normal_flags(). This seems a better fix than fudging PL_compling
  4755. + */
  4756. + SvREADONLY_off(((SVOP*)modname)->op_sv);
  4757. + modname->op_private |= OPpCONST_BARE;
  4758. + if (ver) {
  4759. + veop = newSVOP(OP_CONST, 0, ver);
  4760. + }
  4761. + else
  4762. + veop = NULL;
  4763. + if (flags & PERL_LOADMOD_NOIMPORT) {
  4764. + imop = sawparens(newNULLLIST());
  4765. + }
  4766. + else if (flags & PERL_LOADMOD_IMPORT_OPS) {
  4767. + imop = va_arg(*args, OP*);
  4768. + }
  4769. + else {
  4770. + SV *sv;
  4771. + imop = NULL;
  4772. + sv = va_arg(*args, SV*);
  4773. + while (sv) {
  4774. + imop = append_elem(OP_LIST, imop, newSVOP(OP_CONST, 0, sv));
  4775. + sv = va_arg(*args, SV*);
  4776. + }
  4777. + }
  4778. + {
  4779. + const line_t ocopline = PL_copline;
  4780. + COP * const ocurcop = PL_curcop;
  4781. + const int oexpect = PL_expect;
  4782. +
  4783. +#if (PERL_BCDVERSION >= 0x5004000)
  4784. + utilize(!(flags & PERL_LOADMOD_DENY), start_subparse(FALSE, 0),
  4785. + veop, modname, imop);
  4786. +#else
  4787. + utilize(!(flags & PERL_LOADMOD_DENY), start_subparse(),
  4788. + modname, imop);
  4789. +#endif
  4790. + PL_expect = oexpect;
  4791. + PL_copline = ocopline;
  4792. + PL_curcop = ocurcop;
  4793. + }
  4794. +}
  4795. +
  4796. +#endif
  4797. +#endif
  4798. +
  4799. +#ifndef load_module
  4800. +#if defined(NEED_load_module)
  4801. +static void DPPP_(my_load_module)(U32 flags, SV *name, SV *ver, ...);
  4802. +static
  4803. +#else
  4804. +extern void DPPP_(my_load_module)(U32 flags, SV *name, SV *ver, ...);
  4805. +#endif
  4806. +
  4807. +#ifdef load_module
  4808. +# undef load_module
  4809. +#endif
  4810. +#define load_module DPPP_(my_load_module)
  4811. +#define Perl_load_module DPPP_(my_load_module)
  4812. +
  4813. +#if defined(NEED_load_module) || defined(NEED_load_module_GLOBAL)
  4814. +
  4815. +void
  4816. +DPPP_(my_load_module)(U32 flags, SV *name, SV *ver, ...)
  4817. +{
  4818. + va_list args;
  4819. + va_start(args, ver);
  4820. + vload_module(flags, name, ver, &args);
  4821. + va_end(args);
  4822. +}
  4823. +
  4824. +#endif
  4825. +#endif
  4826. +#ifndef newRV_inc
  4827. +# define newRV_inc(sv) newRV(sv) /* Replace */
  4828. +#endif
  4829. +
  4830. +#ifndef newRV_noinc
  4831. +#if defined(NEED_newRV_noinc)
  4832. +static SV * DPPP_(my_newRV_noinc)(SV *sv);
  4833. +static
  4834. +#else
  4835. +extern SV * DPPP_(my_newRV_noinc)(SV *sv);
  4836. +#endif
  4837. +
  4838. +#ifdef newRV_noinc
  4839. +# undef newRV_noinc
  4840. +#endif
  4841. +#define newRV_noinc(a) DPPP_(my_newRV_noinc)(aTHX_ a)
  4842. +#define Perl_newRV_noinc DPPP_(my_newRV_noinc)
  4843. +
  4844. +#if defined(NEED_newRV_noinc) || defined(NEED_newRV_noinc_GLOBAL)
  4845. +SV *
  4846. +DPPP_(my_newRV_noinc)(SV *sv)
  4847. +{
  4848. + SV *rv = (SV *)newRV(sv);
  4849. + SvREFCNT_dec(sv);
  4850. + return rv;
  4851. +}
  4852. +#endif
  4853. +#endif
  4854. +
  4855. +/* Hint: newCONSTSUB
  4856. + * Returns a CV* as of perl-5.7.1. This return value is not supported
  4857. + * by Devel::PPPort.
  4858. + */
  4859. +
  4860. +/* newCONSTSUB from IO.xs is in the core starting with 5.004_63 */
  4861. +#if (PERL_BCDVERSION < 0x5004063) && (PERL_BCDVERSION != 0x5004005)
  4862. +#if defined(NEED_newCONSTSUB)
  4863. +static void DPPP_(my_newCONSTSUB)(HV *stash, const char *name, SV *sv);
  4864. +static
  4865. +#else
  4866. +extern void DPPP_(my_newCONSTSUB)(HV *stash, const char *name, SV *sv);
  4867. +#endif
  4868. +
  4869. +#ifdef newCONSTSUB
  4870. +# undef newCONSTSUB
  4871. +#endif
  4872. +#define newCONSTSUB(a,b,c) DPPP_(my_newCONSTSUB)(aTHX_ a,b,c)
  4873. +#define Perl_newCONSTSUB DPPP_(my_newCONSTSUB)
  4874. +
  4875. +#if defined(NEED_newCONSTSUB) || defined(NEED_newCONSTSUB_GLOBAL)
  4876. +
  4877. +/* This is just a trick to avoid a dependency of newCONSTSUB on PL_parser */
  4878. +/* (There's no PL_parser in perl < 5.005, so this is completely safe) */
  4879. +#define D_PPP_PL_copline PL_copline
  4880. +
  4881. +void
  4882. +DPPP_(my_newCONSTSUB)(HV *stash, const char *name, SV *sv)
  4883. +{
  4884. + U32 oldhints = PL_hints;
  4885. + HV *old_cop_stash = PL_curcop->cop_stash;
  4886. + HV *old_curstash = PL_curstash;
  4887. + line_t oldline = PL_curcop->cop_line;
  4888. + PL_curcop->cop_line = D_PPP_PL_copline;
  4889. +
  4890. + PL_hints &= ~HINT_BLOCK_SCOPE;
  4891. + if (stash)
  4892. + PL_curstash = PL_curcop->cop_stash = stash;
  4893. +
  4894. + newSUB(
  4895. +
  4896. +#if (PERL_BCDVERSION < 0x5003022)
  4897. + start_subparse(),
  4898. +#elif (PERL_BCDVERSION == 0x5003022)
  4899. + start_subparse(0),
  4900. +#else /* 5.003_23 onwards */
  4901. + start_subparse(FALSE, 0),
  4902. +#endif
  4903. +
  4904. + newSVOP(OP_CONST, 0, newSVpv((char *) name, 0)),
  4905. + newSVOP(OP_CONST, 0, &PL_sv_no), /* SvPV(&PL_sv_no) == "" -- GMB */
  4906. + newSTATEOP(0, Nullch, newSVOP(OP_CONST, 0, sv))
  4907. + );
  4908. +
  4909. + PL_hints = oldhints;
  4910. + PL_curcop->cop_stash = old_cop_stash;
  4911. + PL_curstash = old_curstash;
  4912. + PL_curcop->cop_line = oldline;
  4913. +}
  4914. +#endif
  4915. +#endif
  4916. +
  4917. +/*
  4918. + * Boilerplate macros for initializing and accessing interpreter-local
  4919. + * data from C. All statics in extensions should be reworked to use
  4920. + * this, if you want to make the extension thread-safe. See ext/re/re.xs
  4921. + * for an example of the use of these macros.
  4922. + *
  4923. + * Code that uses these macros is responsible for the following:
  4924. + * 1. #define MY_CXT_KEY to a unique string, e.g. "DynaLoader_guts"
  4925. + * 2. Declare a typedef named my_cxt_t that is a structure that contains
  4926. + * all the data that needs to be interpreter-local.
  4927. + * 3. Use the START_MY_CXT macro after the declaration of my_cxt_t.
  4928. + * 4. Use the MY_CXT_INIT macro such that it is called exactly once
  4929. + * (typically put in the BOOT: section).
  4930. + * 5. Use the members of the my_cxt_t structure everywhere as
  4931. + * MY_CXT.member.
  4932. + * 6. Use the dMY_CXT macro (a declaration) in all the functions that
  4933. + * access MY_CXT.
  4934. + */
  4935. +
  4936. +#if defined(MULTIPLICITY) || defined(PERL_OBJECT) || \
  4937. + defined(PERL_CAPI) || defined(PERL_IMPLICIT_CONTEXT)
  4938. +
  4939. +#ifndef START_MY_CXT
  4940. +
  4941. +/* This must appear in all extensions that define a my_cxt_t structure,
  4942. + * right after the definition (i.e. at file scope). The non-threads
  4943. + * case below uses it to declare the data as static. */
  4944. +#define START_MY_CXT
  4945. +
  4946. +#if (PERL_BCDVERSION < 0x5004068)
  4947. +/* Fetches the SV that keeps the per-interpreter data. */
  4948. +#define dMY_CXT_SV \
  4949. + SV *my_cxt_sv = get_sv(MY_CXT_KEY, FALSE)
  4950. +#else /* >= perl5.004_68 */
  4951. +#define dMY_CXT_SV \
  4952. + SV *my_cxt_sv = *hv_fetch(PL_modglobal, MY_CXT_KEY, \
  4953. + sizeof(MY_CXT_KEY)-1, TRUE)
  4954. +#endif /* < perl5.004_68 */
  4955. +
  4956. +/* This declaration should be used within all functions that use the
  4957. + * interpreter-local data. */
  4958. +#define dMY_CXT \
  4959. + dMY_CXT_SV; \
  4960. + my_cxt_t *my_cxtp = INT2PTR(my_cxt_t*,SvUV(my_cxt_sv))
  4961. +
  4962. +/* Creates and zeroes the per-interpreter data.
  4963. + * (We allocate my_cxtp in a Perl SV so that it will be released when
  4964. + * the interpreter goes away.) */
  4965. +#define MY_CXT_INIT \
  4966. + dMY_CXT_SV; \
  4967. + /* newSV() allocates one more than needed */ \
  4968. + my_cxt_t *my_cxtp = (my_cxt_t*)SvPVX(newSV(sizeof(my_cxt_t)-1));\
  4969. + Zero(my_cxtp, 1, my_cxt_t); \
  4970. + sv_setuv(my_cxt_sv, PTR2UV(my_cxtp))
  4971. +
  4972. +/* This macro must be used to access members of the my_cxt_t structure.
  4973. + * e.g. MYCXT.some_data */
  4974. +#define MY_CXT (*my_cxtp)
  4975. +
  4976. +/* Judicious use of these macros can reduce the number of times dMY_CXT
  4977. + * is used. Use is similar to pTHX, aTHX etc. */
  4978. +#define pMY_CXT my_cxt_t *my_cxtp
  4979. +#define pMY_CXT_ pMY_CXT,
  4980. +#define _pMY_CXT ,pMY_CXT
  4981. +#define aMY_CXT my_cxtp
  4982. +#define aMY_CXT_ aMY_CXT,
  4983. +#define _aMY_CXT ,aMY_CXT
  4984. +
  4985. +#endif /* START_MY_CXT */
  4986. +
  4987. +#ifndef MY_CXT_CLONE
  4988. +/* Clones the per-interpreter data. */
  4989. +#define MY_CXT_CLONE \
  4990. + dMY_CXT_SV; \
  4991. + my_cxt_t *my_cxtp = (my_cxt_t*)SvPVX(newSV(sizeof(my_cxt_t)-1));\
  4992. + Copy(INT2PTR(my_cxt_t*, SvUV(my_cxt_sv)), my_cxtp, 1, my_cxt_t);\
  4993. + sv_setuv(my_cxt_sv, PTR2UV(my_cxtp))
  4994. +#endif
  4995. +
  4996. +#else /* single interpreter */
  4997. +
  4998. +#ifndef START_MY_CXT
  4999. +
  5000. +#define START_MY_CXT static my_cxt_t my_cxt;
  5001. +#define dMY_CXT_SV dNOOP
  5002. +#define dMY_CXT dNOOP
  5003. +#define MY_CXT_INIT NOOP
  5004. +#define MY_CXT my_cxt
  5005. +
  5006. +#define pMY_CXT void
  5007. +#define pMY_CXT_
  5008. +#define _pMY_CXT
  5009. +#define aMY_CXT
  5010. +#define aMY_CXT_
  5011. +#define _aMY_CXT
  5012. +
  5013. +#endif /* START_MY_CXT */
  5014. +
  5015. +#ifndef MY_CXT_CLONE
  5016. +#define MY_CXT_CLONE NOOP
  5017. +#endif
  5018. +
  5019. +#endif
  5020. +
  5021. +#ifndef IVdf
  5022. +# if IVSIZE == LONGSIZE
  5023. +# define IVdf "ld"
  5024. +# define UVuf "lu"
  5025. +# define UVof "lo"
  5026. +# define UVxf "lx"
  5027. +# define UVXf "lX"
  5028. +# elif IVSIZE == INTSIZE
  5029. +# define IVdf "d"
  5030. +# define UVuf "u"
  5031. +# define UVof "o"
  5032. +# define UVxf "x"
  5033. +# define UVXf "X"
  5034. +# else
  5035. +# error "cannot define IV/UV formats"
  5036. +# endif
  5037. +#endif
  5038. +
  5039. +#ifndef NVef
  5040. +# if defined(USE_LONG_DOUBLE) && defined(HAS_LONG_DOUBLE) && \
  5041. + defined(PERL_PRIfldbl) && (PERL_BCDVERSION != 0x5006000)
  5042. + /* Not very likely, but let's try anyway. */
  5043. +# define NVef PERL_PRIeldbl
  5044. +# define NVff PERL_PRIfldbl
  5045. +# define NVgf PERL_PRIgldbl
  5046. +# else
  5047. +# define NVef "e"
  5048. +# define NVff "f"
  5049. +# define NVgf "g"
  5050. +# endif
  5051. +#endif
  5052. +
  5053. +#ifndef SvREFCNT_inc
  5054. +# ifdef PERL_USE_GCC_BRACE_GROUPS
  5055. +# define SvREFCNT_inc(sv) \
  5056. + ({ \
  5057. + SV * const _sv = (SV*)(sv); \
  5058. + if (_sv) \
  5059. + (SvREFCNT(_sv))++; \
  5060. + _sv; \
  5061. + })
  5062. +# else
  5063. +# define SvREFCNT_inc(sv) \
  5064. + ((PL_Sv=(SV*)(sv)) ? (++(SvREFCNT(PL_Sv)),PL_Sv) : NULL)
  5065. +# endif
  5066. +#endif
  5067. +
  5068. +#ifndef SvREFCNT_inc_simple
  5069. +# ifdef PERL_USE_GCC_BRACE_GROUPS
  5070. +# define SvREFCNT_inc_simple(sv) \
  5071. + ({ \
  5072. + if (sv) \
  5073. + (SvREFCNT(sv))++; \
  5074. + (SV *)(sv); \
  5075. + })
  5076. +# else
  5077. +# define SvREFCNT_inc_simple(sv) \
  5078. + ((sv) ? (SvREFCNT(sv)++,(SV*)(sv)) : NULL)
  5079. +# endif
  5080. +#endif
  5081. +
  5082. +#ifndef SvREFCNT_inc_NN
  5083. +# ifdef PERL_USE_GCC_BRACE_GROUPS
  5084. +# define SvREFCNT_inc_NN(sv) \
  5085. + ({ \
  5086. + SV * const _sv = (SV*)(sv); \
  5087. + SvREFCNT(_sv)++; \
  5088. + _sv; \
  5089. + })
  5090. +# else
  5091. +# define SvREFCNT_inc_NN(sv) \
  5092. + (PL_Sv=(SV*)(sv),++(SvREFCNT(PL_Sv)),PL_Sv)
  5093. +# endif
  5094. +#endif
  5095. +
  5096. +#ifndef SvREFCNT_inc_void
  5097. +# ifdef PERL_USE_GCC_BRACE_GROUPS
  5098. +# define SvREFCNT_inc_void(sv) \
  5099. + ({ \
  5100. + SV * const _sv = (SV*)(sv); \
  5101. + if (_sv) \
  5102. + (void)(SvREFCNT(_sv)++); \
  5103. + })
  5104. +# else
  5105. +# define SvREFCNT_inc_void(sv) \
  5106. + (void)((PL_Sv=(SV*)(sv)) ? ++(SvREFCNT(PL_Sv)) : 0)
  5107. +# endif
  5108. +#endif
  5109. +#ifndef SvREFCNT_inc_simple_void
  5110. +# define SvREFCNT_inc_simple_void(sv) STMT_START { if (sv) SvREFCNT(sv)++; } STMT_END
  5111. +#endif
  5112. +
  5113. +#ifndef SvREFCNT_inc_simple_NN
  5114. +# define SvREFCNT_inc_simple_NN(sv) (++SvREFCNT(sv), (SV*)(sv))
  5115. +#endif
  5116. +
  5117. +#ifndef SvREFCNT_inc_void_NN
  5118. +# define SvREFCNT_inc_void_NN(sv) (void)(++SvREFCNT((SV*)(sv)))
  5119. +#endif
  5120. +
  5121. +#ifndef SvREFCNT_inc_simple_void_NN
  5122. +# define SvREFCNT_inc_simple_void_NN(sv) (void)(++SvREFCNT((SV*)(sv)))
  5123. +#endif
  5124. +
  5125. +#ifndef newSV_type
  5126. +
  5127. +#if defined(NEED_newSV_type)
  5128. +static SV* DPPP_(my_newSV_type)(pTHX_ svtype const t);
  5129. +static
  5130. +#else
  5131. +extern SV* DPPP_(my_newSV_type)(pTHX_ svtype const t);
  5132. +#endif
  5133. +
  5134. +#ifdef newSV_type
  5135. +# undef newSV_type
  5136. +#endif
  5137. +#define newSV_type(a) DPPP_(my_newSV_type)(aTHX_ a)
  5138. +#define Perl_newSV_type DPPP_(my_newSV_type)
  5139. +
  5140. +#if defined(NEED_newSV_type) || defined(NEED_newSV_type_GLOBAL)
  5141. +
  5142. +SV*
  5143. +DPPP_(my_newSV_type)(pTHX_ svtype const t)
  5144. +{
  5145. + SV* const sv = newSV(0);
  5146. + sv_upgrade(sv, t);
  5147. + return sv;
  5148. +}
  5149. +
  5150. +#endif
  5151. +
  5152. +#endif
  5153. +
  5154. +#if (PERL_BCDVERSION < 0x5006000)
  5155. +# define D_PPP_CONSTPV_ARG(x) ((char *) (x))
  5156. +#else
  5157. +# define D_PPP_CONSTPV_ARG(x) (x)
  5158. +#endif
  5159. +#ifndef newSVpvn
  5160. +# define newSVpvn(data,len) ((data) \
  5161. + ? ((len) ? newSVpv((data), (len)) : newSVpv("", 0)) \
  5162. + : newSV(0))
  5163. +#endif
  5164. +#ifndef newSVpvn_utf8
  5165. +# define newSVpvn_utf8(s, len, u) newSVpvn_flags((s), (len), (u) ? SVf_UTF8 : 0)
  5166. +#endif
  5167. +#ifndef SVf_UTF8
  5168. +# define SVf_UTF8 0
  5169. +#endif
  5170. +
  5171. +#ifndef newSVpvn_flags
  5172. +
  5173. +#if defined(NEED_newSVpvn_flags)
  5174. +static SV * DPPP_(my_newSVpvn_flags)(pTHX_ const char *s, STRLEN len, U32 flags);
  5175. +static
  5176. +#else
  5177. +extern SV * DPPP_(my_newSVpvn_flags)(pTHX_ const char *s, STRLEN len, U32 flags);
  5178. +#endif
  5179. +
  5180. +#ifdef newSVpvn_flags
  5181. +# undef newSVpvn_flags
  5182. +#endif
  5183. +#define newSVpvn_flags(a,b,c) DPPP_(my_newSVpvn_flags)(aTHX_ a,b,c)
  5184. +#define Perl_newSVpvn_flags DPPP_(my_newSVpvn_flags)
  5185. +
  5186. +#if defined(NEED_newSVpvn_flags) || defined(NEED_newSVpvn_flags_GLOBAL)
  5187. +
  5188. +SV *
  5189. +DPPP_(my_newSVpvn_flags)(pTHX_ const char *s, STRLEN len, U32 flags)
  5190. +{
  5191. + SV *sv = newSVpvn(D_PPP_CONSTPV_ARG(s), len);
  5192. + SvFLAGS(sv) |= (flags & SVf_UTF8);
  5193. + return (flags & SVs_TEMP) ? sv_2mortal(sv) : sv;
  5194. +}
  5195. +
  5196. +#endif
  5197. +
  5198. +#endif
  5199. +
  5200. +/* Backwards compatibility stuff... :-( */
  5201. +#if !defined(NEED_sv_2pv_flags) && defined(NEED_sv_2pv_nolen)
  5202. +# define NEED_sv_2pv_flags
  5203. +#endif
  5204. +#if !defined(NEED_sv_2pv_flags_GLOBAL) && defined(NEED_sv_2pv_nolen_GLOBAL)
  5205. +# define NEED_sv_2pv_flags_GLOBAL
  5206. +#endif
  5207. +
  5208. +/* Hint: sv_2pv_nolen
  5209. + * Use the SvPV_nolen() or SvPV_nolen_const() macros instead of sv_2pv_nolen().
  5210. + */
  5211. +#ifndef sv_2pv_nolen
  5212. +# define sv_2pv_nolen(sv) SvPV_nolen(sv)
  5213. +#endif
  5214. +
  5215. +#ifdef SvPVbyte
  5216. +
  5217. +/* Hint: SvPVbyte
  5218. + * Does not work in perl-5.6.1, ppport.h implements a version
  5219. + * borrowed from perl-5.7.3.
  5220. + */
  5221. +
  5222. +#if (PERL_BCDVERSION < 0x5007000)
  5223. +
  5224. +#if defined(NEED_sv_2pvbyte)
  5225. +static char * DPPP_(my_sv_2pvbyte)(pTHX_ SV *sv, STRLEN *lp);
  5226. +static
  5227. +#else
  5228. +extern char * DPPP_(my_sv_2pvbyte)(pTHX_ SV *sv, STRLEN *lp);
  5229. +#endif
  5230. +
  5231. +#ifdef sv_2pvbyte
  5232. +# undef sv_2pvbyte
  5233. +#endif
  5234. +#define sv_2pvbyte(a,b) DPPP_(my_sv_2pvbyte)(aTHX_ a,b)
  5235. +#define Perl_sv_2pvbyte DPPP_(my_sv_2pvbyte)
  5236. +
  5237. +#if defined(NEED_sv_2pvbyte) || defined(NEED_sv_2pvbyte_GLOBAL)
  5238. +
  5239. +char *
  5240. +DPPP_(my_sv_2pvbyte)(pTHX_ SV *sv, STRLEN *lp)
  5241. +{
  5242. + sv_utf8_downgrade(sv,0);
  5243. + return SvPV(sv,*lp);
  5244. +}
  5245. +
  5246. +#endif
  5247. +
  5248. +/* Hint: sv_2pvbyte
  5249. + * Use the SvPVbyte() macro instead of sv_2pvbyte().
  5250. + */
  5251. +
  5252. +#undef SvPVbyte
  5253. +
  5254. +#define SvPVbyte(sv, lp) \
  5255. + ((SvFLAGS(sv) & (SVf_POK|SVf_UTF8)) == (SVf_POK) \
  5256. + ? ((lp = SvCUR(sv)), SvPVX(sv)) : sv_2pvbyte(sv, &lp))
  5257. +
  5258. +#endif
  5259. +
  5260. +#else
  5261. +
  5262. +# define SvPVbyte SvPV
  5263. +# define sv_2pvbyte sv_2pv
  5264. +
  5265. +#endif
  5266. +#ifndef sv_2pvbyte_nolen
  5267. +# define sv_2pvbyte_nolen(sv) sv_2pv_nolen(sv)
  5268. +#endif
  5269. +
  5270. +/* Hint: sv_pvn
  5271. + * Always use the SvPV() macro instead of sv_pvn().
  5272. + */
  5273. +
  5274. +/* Hint: sv_pvn_force
  5275. + * Always use the SvPV_force() macro instead of sv_pvn_force().
  5276. + */
  5277. +
  5278. +/* If these are undefined, they're not handled by the core anyway */
  5279. +#ifndef SV_IMMEDIATE_UNREF
  5280. +# define SV_IMMEDIATE_UNREF 0
  5281. +#endif
  5282. +
  5283. +#ifndef SV_GMAGIC
  5284. +# define SV_GMAGIC 0
  5285. +#endif
  5286. +
  5287. +#ifndef SV_COW_DROP_PV
  5288. +# define SV_COW_DROP_PV 0
  5289. +#endif
  5290. +
  5291. +#ifndef SV_UTF8_NO_ENCODING
  5292. +# define SV_UTF8_NO_ENCODING 0
  5293. +#endif
  5294. +
  5295. +#ifndef SV_NOSTEAL
  5296. +# define SV_NOSTEAL 0
  5297. +#endif
  5298. +
  5299. +#ifndef SV_CONST_RETURN
  5300. +# define SV_CONST_RETURN 0
  5301. +#endif
  5302. +
  5303. +#ifndef SV_MUTABLE_RETURN
  5304. +# define SV_MUTABLE_RETURN 0
  5305. +#endif
  5306. +
  5307. +#ifndef SV_SMAGIC
  5308. +# define SV_SMAGIC 0
  5309. +#endif
  5310. +
  5311. +#ifndef SV_HAS_TRAILING_NUL
  5312. +# define SV_HAS_TRAILING_NUL 0
  5313. +#endif
  5314. +
  5315. +#ifndef SV_COW_SHARED_HASH_KEYS
  5316. +# define SV_COW_SHARED_HASH_KEYS 0
  5317. +#endif
  5318. +
  5319. +#if (PERL_BCDVERSION < 0x5007002)
  5320. +
  5321. +#if defined(NEED_sv_2pv_flags)
  5322. +static char * DPPP_(my_sv_2pv_flags)(pTHX_ SV *sv, STRLEN *lp, I32 flags);
  5323. +static
  5324. +#else
  5325. +extern char * DPPP_(my_sv_2pv_flags)(pTHX_ SV *sv, STRLEN *lp, I32 flags);
  5326. +#endif
  5327. +
  5328. +#ifdef sv_2pv_flags
  5329. +# undef sv_2pv_flags
  5330. +#endif
  5331. +#define sv_2pv_flags(a,b,c) DPPP_(my_sv_2pv_flags)(aTHX_ a,b,c)
  5332. +#define Perl_sv_2pv_flags DPPP_(my_sv_2pv_flags)
  5333. +
  5334. +#if defined(NEED_sv_2pv_flags) || defined(NEED_sv_2pv_flags_GLOBAL)
  5335. +
  5336. +char *
  5337. +DPPP_(my_sv_2pv_flags)(pTHX_ SV *sv, STRLEN *lp, I32 flags)
  5338. +{
  5339. + STRLEN n_a = (STRLEN) flags;
  5340. + return sv_2pv(sv, lp ? lp : &n_a);
  5341. +}
  5342. +
  5343. +#endif
  5344. +
  5345. +#if defined(NEED_sv_pvn_force_flags)
  5346. +static char * DPPP_(my_sv_pvn_force_flags)(pTHX_ SV *sv, STRLEN *lp, I32 flags);
  5347. +static
  5348. +#else
  5349. +extern char * DPPP_(my_sv_pvn_force_flags)(pTHX_ SV *sv, STRLEN *lp, I32 flags);
  5350. +#endif
  5351. +
  5352. +#ifdef sv_pvn_force_flags
  5353. +# undef sv_pvn_force_flags
  5354. +#endif
  5355. +#define sv_pvn_force_flags(a,b,c) DPPP_(my_sv_pvn_force_flags)(aTHX_ a,b,c)
  5356. +#define Perl_sv_pvn_force_flags DPPP_(my_sv_pvn_force_flags)
  5357. +
  5358. +#if defined(NEED_sv_pvn_force_flags) || defined(NEED_sv_pvn_force_flags_GLOBAL)
  5359. +
  5360. +char *
  5361. +DPPP_(my_sv_pvn_force_flags)(pTHX_ SV *sv, STRLEN *lp, I32 flags)
  5362. +{
  5363. + STRLEN n_a = (STRLEN) flags;
  5364. + return sv_pvn_force(sv, lp ? lp : &n_a);
  5365. +}
  5366. +
  5367. +#endif
  5368. +
  5369. +#endif
  5370. +
  5371. +#if (PERL_BCDVERSION < 0x5008008) || ( (PERL_BCDVERSION >= 0x5009000) && (PERL_BCDVERSION < 0x5009003) )
  5372. +# define DPPP_SVPV_NOLEN_LP_ARG &PL_na
  5373. +#else
  5374. +# define DPPP_SVPV_NOLEN_LP_ARG 0
  5375. +#endif
  5376. +#ifndef SvPV_const
  5377. +# define SvPV_const(sv, lp) SvPV_flags_const(sv, lp, SV_GMAGIC)
  5378. +#endif
  5379. +
  5380. +#ifndef SvPV_mutable
  5381. +# define SvPV_mutable(sv, lp) SvPV_flags_mutable(sv, lp, SV_GMAGIC)
  5382. +#endif
  5383. +#ifndef SvPV_flags
  5384. +# define SvPV_flags(sv, lp, flags) \
  5385. + ((SvFLAGS(sv) & (SVf_POK)) == SVf_POK \
  5386. + ? ((lp = SvCUR(sv)), SvPVX(sv)) : sv_2pv_flags(sv, &lp, flags))
  5387. +#endif
  5388. +#ifndef SvPV_flags_const
  5389. +# define SvPV_flags_const(sv, lp, flags) \
  5390. + ((SvFLAGS(sv) & (SVf_POK)) == SVf_POK \
  5391. + ? ((lp = SvCUR(sv)), SvPVX_const(sv)) : \
  5392. + (const char*) sv_2pv_flags(sv, &lp, flags|SV_CONST_RETURN))
  5393. +#endif
  5394. +#ifndef SvPV_flags_const_nolen
  5395. +# define SvPV_flags_const_nolen(sv, flags) \
  5396. + ((SvFLAGS(sv) & (SVf_POK)) == SVf_POK \
  5397. + ? SvPVX_const(sv) : \
  5398. + (const char*) sv_2pv_flags(sv, DPPP_SVPV_NOLEN_LP_ARG, flags|SV_CONST_RETURN))
  5399. +#endif
  5400. +#ifndef SvPV_flags_mutable
  5401. +# define SvPV_flags_mutable(sv, lp, flags) \
  5402. + ((SvFLAGS(sv) & (SVf_POK)) == SVf_POK \
  5403. + ? ((lp = SvCUR(sv)), SvPVX_mutable(sv)) : \
  5404. + sv_2pv_flags(sv, &lp, flags|SV_MUTABLE_RETURN))
  5405. +#endif
  5406. +#ifndef SvPV_force
  5407. +# define SvPV_force(sv, lp) SvPV_force_flags(sv, lp, SV_GMAGIC)
  5408. +#endif
  5409. +
  5410. +#ifndef SvPV_force_nolen
  5411. +# define SvPV_force_nolen(sv) SvPV_force_flags_nolen(sv, SV_GMAGIC)
  5412. +#endif
  5413. +
  5414. +#ifndef SvPV_force_mutable
  5415. +# define SvPV_force_mutable(sv, lp) SvPV_force_flags_mutable(sv, lp, SV_GMAGIC)
  5416. +#endif
  5417. +
  5418. +#ifndef SvPV_force_nomg
  5419. +# define SvPV_force_nomg(sv, lp) SvPV_force_flags(sv, lp, 0)
  5420. +#endif
  5421. +
  5422. +#ifndef SvPV_force_nomg_nolen
  5423. +# define SvPV_force_nomg_nolen(sv) SvPV_force_flags_nolen(sv, 0)
  5424. +#endif
  5425. +#ifndef SvPV_force_flags
  5426. +# define SvPV_force_flags(sv, lp, flags) \
  5427. + ((SvFLAGS(sv) & (SVf_POK|SVf_THINKFIRST)) == SVf_POK \
  5428. + ? ((lp = SvCUR(sv)), SvPVX(sv)) : sv_pvn_force_flags(sv, &lp, flags))
  5429. +#endif
  5430. +#ifndef SvPV_force_flags_nolen
  5431. +# define SvPV_force_flags_nolen(sv, flags) \
  5432. + ((SvFLAGS(sv) & (SVf_POK|SVf_THINKFIRST)) == SVf_POK \
  5433. + ? SvPVX(sv) : sv_pvn_force_flags(sv, DPPP_SVPV_NOLEN_LP_ARG, flags))
  5434. +#endif
  5435. +#ifndef SvPV_force_flags_mutable
  5436. +# define SvPV_force_flags_mutable(sv, lp, flags) \
  5437. + ((SvFLAGS(sv) & (SVf_POK|SVf_THINKFIRST)) == SVf_POK \
  5438. + ? ((lp = SvCUR(sv)), SvPVX_mutable(sv)) \
  5439. + : sv_pvn_force_flags(sv, &lp, flags|SV_MUTABLE_RETURN))
  5440. +#endif
  5441. +#ifndef SvPV_nolen
  5442. +# define SvPV_nolen(sv) \
  5443. + ((SvFLAGS(sv) & (SVf_POK)) == SVf_POK \
  5444. + ? SvPVX(sv) : sv_2pv_flags(sv, DPPP_SVPV_NOLEN_LP_ARG, SV_GMAGIC))
  5445. +#endif
  5446. +#ifndef SvPV_nolen_const
  5447. +# define SvPV_nolen_const(sv) \
  5448. + ((SvFLAGS(sv) & (SVf_POK)) == SVf_POK \
  5449. + ? SvPVX_const(sv) : sv_2pv_flags(sv, DPPP_SVPV_NOLEN_LP_ARG, SV_GMAGIC|SV_CONST_RETURN))
  5450. +#endif
  5451. +#ifndef SvPV_nomg
  5452. +# define SvPV_nomg(sv, lp) SvPV_flags(sv, lp, 0)
  5453. +#endif
  5454. +
  5455. +#ifndef SvPV_nomg_const
  5456. +# define SvPV_nomg_const(sv, lp) SvPV_flags_const(sv, lp, 0)
  5457. +#endif
  5458. +
  5459. +#ifndef SvPV_nomg_const_nolen
  5460. +# define SvPV_nomg_const_nolen(sv) SvPV_flags_const_nolen(sv, 0)
  5461. +#endif
  5462. +
  5463. +#ifndef SvPV_nomg_nolen
  5464. +# define SvPV_nomg_nolen(sv) ((SvFLAGS(sv) & (SVf_POK)) == SVf_POK \
  5465. + ? SvPVX(sv) : sv_2pv_flags(sv, DPPP_SVPV_NOLEN_LP_ARG, 0))
  5466. +#endif
  5467. +#ifndef SvPV_renew
  5468. +# define SvPV_renew(sv,n) STMT_START { SvLEN_set(sv, n); \
  5469. + SvPV_set((sv), (char *) saferealloc( \
  5470. + (Malloc_t)SvPVX(sv), (MEM_SIZE)((n)))); \
  5471. + } STMT_END
  5472. +#endif
  5473. +#ifndef SvMAGIC_set
  5474. +# define SvMAGIC_set(sv, val) \
  5475. + STMT_START { assert(SvTYPE(sv) >= SVt_PVMG); \
  5476. + (((XPVMG*) SvANY(sv))->xmg_magic = (val)); } STMT_END
  5477. +#endif
  5478. +
  5479. +#if (PERL_BCDVERSION < 0x5009003)
  5480. +#ifndef SvPVX_const
  5481. +# define SvPVX_const(sv) ((const char*) (0 + SvPVX(sv)))
  5482. +#endif
  5483. +
  5484. +#ifndef SvPVX_mutable
  5485. +# define SvPVX_mutable(sv) (0 + SvPVX(sv))
  5486. +#endif
  5487. +#ifndef SvRV_set
  5488. +# define SvRV_set(sv, val) \
  5489. + STMT_START { assert(SvTYPE(sv) >= SVt_RV); \
  5490. + (((XRV*) SvANY(sv))->xrv_rv = (val)); } STMT_END
  5491. +#endif
  5492. +
  5493. +#else
  5494. +#ifndef SvPVX_const
  5495. +# define SvPVX_const(sv) ((const char*)((sv)->sv_u.svu_pv))
  5496. +#endif
  5497. +
  5498. +#ifndef SvPVX_mutable
  5499. +# define SvPVX_mutable(sv) ((sv)->sv_u.svu_pv)
  5500. +#endif
  5501. +#ifndef SvRV_set
  5502. +# define SvRV_set(sv, val) \
  5503. + STMT_START { assert(SvTYPE(sv) >= SVt_RV); \
  5504. + ((sv)->sv_u.svu_rv = (val)); } STMT_END
  5505. +#endif
  5506. +
  5507. +#endif
  5508. +#ifndef SvSTASH_set
  5509. +# define SvSTASH_set(sv, val) \
  5510. + STMT_START { assert(SvTYPE(sv) >= SVt_PVMG); \
  5511. + (((XPVMG*) SvANY(sv))->xmg_stash = (val)); } STMT_END
  5512. +#endif
  5513. +
  5514. +#if (PERL_BCDVERSION < 0x5004000)
  5515. +#ifndef SvUV_set
  5516. +# define SvUV_set(sv, val) \
  5517. + STMT_START { assert(SvTYPE(sv) == SVt_IV || SvTYPE(sv) >= SVt_PVIV); \
  5518. + (((XPVIV*) SvANY(sv))->xiv_iv = (IV) (val)); } STMT_END
  5519. +#endif
  5520. +
  5521. +#else
  5522. +#ifndef SvUV_set
  5523. +# define SvUV_set(sv, val) \
  5524. + STMT_START { assert(SvTYPE(sv) == SVt_IV || SvTYPE(sv) >= SVt_PVIV); \
  5525. + (((XPVUV*) SvANY(sv))->xuv_uv = (val)); } STMT_END
  5526. +#endif
  5527. +
  5528. +#endif
  5529. +
  5530. +#if (PERL_BCDVERSION >= 0x5004000) && !defined(vnewSVpvf)
  5531. +#if defined(NEED_vnewSVpvf)
  5532. +static SV * DPPP_(my_vnewSVpvf)(pTHX_ const char *pat, va_list *args);
  5533. +static
  5534. +#else
  5535. +extern SV * DPPP_(my_vnewSVpvf)(pTHX_ const char *pat, va_list *args);
  5536. +#endif
  5537. +
  5538. +#ifdef vnewSVpvf
  5539. +# undef vnewSVpvf
  5540. +#endif
  5541. +#define vnewSVpvf(a,b) DPPP_(my_vnewSVpvf)(aTHX_ a,b)
  5542. +#define Perl_vnewSVpvf DPPP_(my_vnewSVpvf)
  5543. +
  5544. +#if defined(NEED_vnewSVpvf) || defined(NEED_vnewSVpvf_GLOBAL)
  5545. +
  5546. +SV *
  5547. +DPPP_(my_vnewSVpvf)(pTHX_ const char *pat, va_list *args)
  5548. +{
  5549. + register SV *sv = newSV(0);
  5550. + sv_vsetpvfn(sv, pat, strlen(pat), args, Null(SV**), 0, Null(bool*));
  5551. + return sv;
  5552. +}
  5553. +
  5554. +#endif
  5555. +#endif
  5556. +
  5557. +#if (PERL_BCDVERSION >= 0x5004000) && !defined(sv_vcatpvf)
  5558. +# define sv_vcatpvf(sv, pat, args) sv_vcatpvfn(sv, pat, strlen(pat), args, Null(SV**), 0, Null(bool*))
  5559. +#endif
  5560. +
  5561. +#if (PERL_BCDVERSION >= 0x5004000) && !defined(sv_vsetpvf)
  5562. +# define sv_vsetpvf(sv, pat, args) sv_vsetpvfn(sv, pat, strlen(pat), args, Null(SV**), 0, Null(bool*))
  5563. +#endif
  5564. +
  5565. +#if (PERL_BCDVERSION >= 0x5004000) && !defined(sv_catpvf_mg)
  5566. +#if defined(NEED_sv_catpvf_mg)
  5567. +static void DPPP_(my_sv_catpvf_mg)(pTHX_ SV *sv, const char *pat, ...);
  5568. +static
  5569. +#else
  5570. +extern void DPPP_(my_sv_catpvf_mg)(pTHX_ SV *sv, const char *pat, ...);
  5571. +#endif
  5572. +
  5573. +#define Perl_sv_catpvf_mg DPPP_(my_sv_catpvf_mg)
  5574. +
  5575. +#if defined(NEED_sv_catpvf_mg) || defined(NEED_sv_catpvf_mg_GLOBAL)
  5576. +
  5577. +void
  5578. +DPPP_(my_sv_catpvf_mg)(pTHX_ SV *sv, const char *pat, ...)
  5579. +{
  5580. + va_list args;
  5581. + va_start(args, pat);
  5582. + sv_vcatpvfn(sv, pat, strlen(pat), &args, Null(SV**), 0, Null(bool*));
  5583. + SvSETMAGIC(sv);
  5584. + va_end(args);
  5585. +}
  5586. +
  5587. +#endif
  5588. +#endif
  5589. +
  5590. +#ifdef PERL_IMPLICIT_CONTEXT
  5591. +#if (PERL_BCDVERSION >= 0x5004000) && !defined(sv_catpvf_mg_nocontext)
  5592. +#if defined(NEED_sv_catpvf_mg_nocontext)
  5593. +static void DPPP_(my_sv_catpvf_mg_nocontext)(SV *sv, const char *pat, ...);
  5594. +static
  5595. +#else
  5596. +extern void DPPP_(my_sv_catpvf_mg_nocontext)(SV *sv, const char *pat, ...);
  5597. +#endif
  5598. +
  5599. +#define sv_catpvf_mg_nocontext DPPP_(my_sv_catpvf_mg_nocontext)
  5600. +#define Perl_sv_catpvf_mg_nocontext DPPP_(my_sv_catpvf_mg_nocontext)
  5601. +
  5602. +#if defined(NEED_sv_catpvf_mg_nocontext) || defined(NEED_sv_catpvf_mg_nocontext_GLOBAL)
  5603. +
  5604. +void
  5605. +DPPP_(my_sv_catpvf_mg_nocontext)(SV *sv, const char *pat, ...)
  5606. +{
  5607. + dTHX;
  5608. + va_list args;
  5609. + va_start(args, pat);
  5610. + sv_vcatpvfn(sv, pat, strlen(pat), &args, Null(SV**), 0, Null(bool*));
  5611. + SvSETMAGIC(sv);
  5612. + va_end(args);
  5613. +}
  5614. +
  5615. +#endif
  5616. +#endif
  5617. +#endif
  5618. +
  5619. +/* sv_catpvf_mg depends on sv_catpvf_mg_nocontext */
  5620. +#ifndef sv_catpvf_mg
  5621. +# ifdef PERL_IMPLICIT_CONTEXT
  5622. +# define sv_catpvf_mg Perl_sv_catpvf_mg_nocontext
  5623. +# else
  5624. +# define sv_catpvf_mg Perl_sv_catpvf_mg
  5625. +# endif
  5626. +#endif
  5627. +
  5628. +#if (PERL_BCDVERSION >= 0x5004000) && !defined(sv_vcatpvf_mg)
  5629. +# define sv_vcatpvf_mg(sv, pat, args) \
  5630. + STMT_START { \
  5631. + sv_vcatpvfn(sv, pat, strlen(pat), args, Null(SV**), 0, Null(bool*)); \
  5632. + SvSETMAGIC(sv); \
  5633. + } STMT_END
  5634. +#endif
  5635. +
  5636. +#if (PERL_BCDVERSION >= 0x5004000) && !defined(sv_setpvf_mg)
  5637. +#if defined(NEED_sv_setpvf_mg)
  5638. +static void DPPP_(my_sv_setpvf_mg)(pTHX_ SV *sv, const char *pat, ...);
  5639. +static
  5640. +#else
  5641. +extern void DPPP_(my_sv_setpvf_mg)(pTHX_ SV *sv, const char *pat, ...);
  5642. +#endif
  5643. +
  5644. +#define Perl_sv_setpvf_mg DPPP_(my_sv_setpvf_mg)
  5645. +
  5646. +#if defined(NEED_sv_setpvf_mg) || defined(NEED_sv_setpvf_mg_GLOBAL)
  5647. +
  5648. +void
  5649. +DPPP_(my_sv_setpvf_mg)(pTHX_ SV *sv, const char *pat, ...)
  5650. +{
  5651. + va_list args;
  5652. + va_start(args, pat);
  5653. + sv_vsetpvfn(sv, pat, strlen(pat), &args, Null(SV**), 0, Null(bool*));
  5654. + SvSETMAGIC(sv);
  5655. + va_end(args);
  5656. +}
  5657. +
  5658. +#endif
  5659. +#endif
  5660. +
  5661. +#ifdef PERL_IMPLICIT_CONTEXT
  5662. +#if (PERL_BCDVERSION >= 0x5004000) && !defined(sv_setpvf_mg_nocontext)
  5663. +#if defined(NEED_sv_setpvf_mg_nocontext)
  5664. +static void DPPP_(my_sv_setpvf_mg_nocontext)(SV *sv, const char *pat, ...);
  5665. +static
  5666. +#else
  5667. +extern void DPPP_(my_sv_setpvf_mg_nocontext)(SV *sv, const char *pat, ...);
  5668. +#endif
  5669. +
  5670. +#define sv_setpvf_mg_nocontext DPPP_(my_sv_setpvf_mg_nocontext)
  5671. +#define Perl_sv_setpvf_mg_nocontext DPPP_(my_sv_setpvf_mg_nocontext)
  5672. +
  5673. +#if defined(NEED_sv_setpvf_mg_nocontext) || defined(NEED_sv_setpvf_mg_nocontext_GLOBAL)
  5674. +
  5675. +void
  5676. +DPPP_(my_sv_setpvf_mg_nocontext)(SV *sv, const char *pat, ...)
  5677. +{
  5678. + dTHX;
  5679. + va_list args;
  5680. + va_start(args, pat);
  5681. + sv_vsetpvfn(sv, pat, strlen(pat), &args, Null(SV**), 0, Null(bool*));
  5682. + SvSETMAGIC(sv);
  5683. + va_end(args);
  5684. +}
  5685. +
  5686. +#endif
  5687. +#endif
  5688. +#endif
  5689. +
  5690. +/* sv_setpvf_mg depends on sv_setpvf_mg_nocontext */
  5691. +#ifndef sv_setpvf_mg
  5692. +# ifdef PERL_IMPLICIT_CONTEXT
  5693. +# define sv_setpvf_mg Perl_sv_setpvf_mg_nocontext
  5694. +# else
  5695. +# define sv_setpvf_mg Perl_sv_setpvf_mg
  5696. +# endif
  5697. +#endif
  5698. +
  5699. +#if (PERL_BCDVERSION >= 0x5004000) && !defined(sv_vsetpvf_mg)
  5700. +# define sv_vsetpvf_mg(sv, pat, args) \
  5701. + STMT_START { \
  5702. + sv_vsetpvfn(sv, pat, strlen(pat), args, Null(SV**), 0, Null(bool*)); \
  5703. + SvSETMAGIC(sv); \
  5704. + } STMT_END
  5705. +#endif
  5706. +
  5707. +/* Hint: newSVpvn_share
  5708. + * The SVs created by this function only mimic the behaviour of
  5709. + * shared PVs without really being shared. Only use if you know
  5710. + * what you're doing.
  5711. + */
  5712. +
  5713. +#ifndef newSVpvn_share
  5714. +
  5715. +#if defined(NEED_newSVpvn_share)
  5716. +static SV * DPPP_(my_newSVpvn_share)(pTHX_ const char *src, I32 len, U32 hash);
  5717. +static
  5718. +#else
  5719. +extern SV * DPPP_(my_newSVpvn_share)(pTHX_ const char *src, I32 len, U32 hash);
  5720. +#endif
  5721. +
  5722. +#ifdef newSVpvn_share
  5723. +# undef newSVpvn_share
  5724. +#endif
  5725. +#define newSVpvn_share(a,b,c) DPPP_(my_newSVpvn_share)(aTHX_ a,b,c)
  5726. +#define Perl_newSVpvn_share DPPP_(my_newSVpvn_share)
  5727. +
  5728. +#if defined(NEED_newSVpvn_share) || defined(NEED_newSVpvn_share_GLOBAL)
  5729. +
  5730. +SV *
  5731. +DPPP_(my_newSVpvn_share)(pTHX_ const char *src, I32 len, U32 hash)
  5732. +{
  5733. + SV *sv;
  5734. + if (len < 0)
  5735. + len = -len;
  5736. + if (!hash)
  5737. + PERL_HASH(hash, (char*) src, len);
  5738. + sv = newSVpvn((char *) src, len);
  5739. + sv_upgrade(sv, SVt_PVIV);
  5740. + SvIVX(sv) = hash;
  5741. + SvREADONLY_on(sv);
  5742. + SvPOK_on(sv);
  5743. + return sv;
  5744. +}
  5745. +
  5746. +#endif
  5747. +
  5748. +#endif
  5749. +#ifndef SvSHARED_HASH
  5750. +# define SvSHARED_HASH(sv) (0 + SvUVX(sv))
  5751. +#endif
  5752. +#ifndef HvNAME_get
  5753. +# define HvNAME_get(hv) HvNAME(hv)
  5754. +#endif
  5755. +#ifndef HvNAMELEN_get
  5756. +# define HvNAMELEN_get(hv) (HvNAME_get(hv) ? (I32)strlen(HvNAME_get(hv)) : 0)
  5757. +#endif
  5758. +#ifndef GvSVn
  5759. +# define GvSVn(gv) GvSV(gv)
  5760. +#endif
  5761. +
  5762. +#ifndef isGV_with_GP
  5763. +# define isGV_with_GP(gv) isGV(gv)
  5764. +#endif
  5765. +
  5766. +#ifndef gv_fetchpvn_flags
  5767. +# define gv_fetchpvn_flags(name, len, flags, svt) gv_fetchpv(name, flags, svt)
  5768. +#endif
  5769. +
  5770. +#ifndef gv_fetchsv
  5771. +# define gv_fetchsv(name, flags, svt) gv_fetchpv(SvPV_nolen_const(name), flags, svt)
  5772. +#endif
  5773. +#ifndef get_cvn_flags
  5774. +# define get_cvn_flags(name, namelen, flags) get_cv(name, flags)
  5775. +#endif
  5776. +#ifndef WARN_ALL
  5777. +# define WARN_ALL 0
  5778. +#endif
  5779. +
  5780. +#ifndef WARN_CLOSURE
  5781. +# define WARN_CLOSURE 1
  5782. +#endif
  5783. +
  5784. +#ifndef WARN_DEPRECATED
  5785. +# define WARN_DEPRECATED 2
  5786. +#endif
  5787. +
  5788. +#ifndef WARN_EXITING
  5789. +# define WARN_EXITING 3
  5790. +#endif
  5791. +
  5792. +#ifndef WARN_GLOB
  5793. +# define WARN_GLOB 4
  5794. +#endif
  5795. +
  5796. +#ifndef WARN_IO
  5797. +# define WARN_IO 5
  5798. +#endif
  5799. +
  5800. +#ifndef WARN_CLOSED
  5801. +# define WARN_CLOSED 6
  5802. +#endif
  5803. +
  5804. +#ifndef WARN_EXEC
  5805. +# define WARN_EXEC 7
  5806. +#endif
  5807. +
  5808. +#ifndef WARN_LAYER
  5809. +# define WARN_LAYER 8
  5810. +#endif
  5811. +
  5812. +#ifndef WARN_NEWLINE
  5813. +# define WARN_NEWLINE 9
  5814. +#endif
  5815. +
  5816. +#ifndef WARN_PIPE
  5817. +# define WARN_PIPE 10
  5818. +#endif
  5819. +
  5820. +#ifndef WARN_UNOPENED
  5821. +# define WARN_UNOPENED 11
  5822. +#endif
  5823. +
  5824. +#ifndef WARN_MISC
  5825. +# define WARN_MISC 12
  5826. +#endif
  5827. +
  5828. +#ifndef WARN_NUMERIC
  5829. +# define WARN_NUMERIC 13
  5830. +#endif
  5831. +
  5832. +#ifndef WARN_ONCE
  5833. +# define WARN_ONCE 14
  5834. +#endif
  5835. +
  5836. +#ifndef WARN_OVERFLOW
  5837. +# define WARN_OVERFLOW 15
  5838. +#endif
  5839. +
  5840. +#ifndef WARN_PACK
  5841. +# define WARN_PACK 16
  5842. +#endif
  5843. +
  5844. +#ifndef WARN_PORTABLE
  5845. +# define WARN_PORTABLE 17
  5846. +#endif
  5847. +
  5848. +#ifndef WARN_RECURSION
  5849. +# define WARN_RECURSION 18
  5850. +#endif
  5851. +
  5852. +#ifndef WARN_REDEFINE
  5853. +# define WARN_REDEFINE 19
  5854. +#endif
  5855. +
  5856. +#ifndef WARN_REGEXP
  5857. +# define WARN_REGEXP 20
  5858. +#endif
  5859. +
  5860. +#ifndef WARN_SEVERE
  5861. +# define WARN_SEVERE 21
  5862. +#endif
  5863. +
  5864. +#ifndef WARN_DEBUGGING
  5865. +# define WARN_DEBUGGING 22
  5866. +#endif
  5867. +
  5868. +#ifndef WARN_INPLACE
  5869. +# define WARN_INPLACE 23
  5870. +#endif
  5871. +
  5872. +#ifndef WARN_INTERNAL
  5873. +# define WARN_INTERNAL 24
  5874. +#endif
  5875. +
  5876. +#ifndef WARN_MALLOC
  5877. +# define WARN_MALLOC 25
  5878. +#endif
  5879. +
  5880. +#ifndef WARN_SIGNAL
  5881. +# define WARN_SIGNAL 26
  5882. +#endif
  5883. +
  5884. +#ifndef WARN_SUBSTR
  5885. +# define WARN_SUBSTR 27
  5886. +#endif
  5887. +
  5888. +#ifndef WARN_SYNTAX
  5889. +# define WARN_SYNTAX 28
  5890. +#endif
  5891. +
  5892. +#ifndef WARN_AMBIGUOUS
  5893. +# define WARN_AMBIGUOUS 29
  5894. +#endif
  5895. +
  5896. +#ifndef WARN_BAREWORD
  5897. +# define WARN_BAREWORD 30
  5898. +#endif
  5899. +
  5900. +#ifndef WARN_DIGIT
  5901. +# define WARN_DIGIT 31
  5902. +#endif
  5903. +
  5904. +#ifndef WARN_PARENTHESIS
  5905. +# define WARN_PARENTHESIS 32
  5906. +#endif
  5907. +
  5908. +#ifndef WARN_PRECEDENCE
  5909. +# define WARN_PRECEDENCE 33
  5910. +#endif
  5911. +
  5912. +#ifndef WARN_PRINTF
  5913. +# define WARN_PRINTF 34
  5914. +#endif
  5915. +
  5916. +#ifndef WARN_PROTOTYPE
  5917. +# define WARN_PROTOTYPE 35
  5918. +#endif
  5919. +
  5920. +#ifndef WARN_QW
  5921. +# define WARN_QW 36
  5922. +#endif
  5923. +
  5924. +#ifndef WARN_RESERVED
  5925. +# define WARN_RESERVED 37
  5926. +#endif
  5927. +
  5928. +#ifndef WARN_SEMICOLON
  5929. +# define WARN_SEMICOLON 38
  5930. +#endif
  5931. +
  5932. +#ifndef WARN_TAINT
  5933. +# define WARN_TAINT 39
  5934. +#endif
  5935. +
  5936. +#ifndef WARN_THREADS
  5937. +# define WARN_THREADS 40
  5938. +#endif
  5939. +
  5940. +#ifndef WARN_UNINITIALIZED
  5941. +# define WARN_UNINITIALIZED 41
  5942. +#endif
  5943. +
  5944. +#ifndef WARN_UNPACK
  5945. +# define WARN_UNPACK 42
  5946. +#endif
  5947. +
  5948. +#ifndef WARN_UNTIE
  5949. +# define WARN_UNTIE 43
  5950. +#endif
  5951. +
  5952. +#ifndef WARN_UTF8
  5953. +# define WARN_UTF8 44
  5954. +#endif
  5955. +
  5956. +#ifndef WARN_VOID
  5957. +# define WARN_VOID 45
  5958. +#endif
  5959. +
  5960. +#ifndef WARN_ASSERTIONS
  5961. +# define WARN_ASSERTIONS 46
  5962. +#endif
  5963. +#ifndef packWARN
  5964. +# define packWARN(a) (a)
  5965. +#endif
  5966. +
  5967. +#ifndef ckWARN
  5968. +# ifdef G_WARN_ON
  5969. +# define ckWARN(a) (PL_dowarn & G_WARN_ON)
  5970. +# else
  5971. +# define ckWARN(a) PL_dowarn
  5972. +# endif
  5973. +#endif
  5974. +
  5975. +#if (PERL_BCDVERSION >= 0x5004000) && !defined(warner)
  5976. +#if defined(NEED_warner)
  5977. +static void DPPP_(my_warner)(U32 err, const char *pat, ...);
  5978. +static
  5979. +#else
  5980. +extern void DPPP_(my_warner)(U32 err, const char *pat, ...);
  5981. +#endif
  5982. +
  5983. +#define Perl_warner DPPP_(my_warner)
  5984. +
  5985. +#if defined(NEED_warner) || defined(NEED_warner_GLOBAL)
  5986. +
  5987. +void
  5988. +DPPP_(my_warner)(U32 err, const char *pat, ...)
  5989. +{
  5990. + SV *sv;
  5991. + va_list args;
  5992. +
  5993. + PERL_UNUSED_ARG(err);
  5994. +
  5995. + va_start(args, pat);
  5996. + sv = vnewSVpvf(pat, &args);
  5997. + va_end(args);
  5998. + sv_2mortal(sv);
  5999. + warn("%s", SvPV_nolen(sv));
  6000. +}
  6001. +
  6002. +#define warner Perl_warner
  6003. +
  6004. +#define Perl_warner_nocontext Perl_warner
  6005. +
  6006. +#endif
  6007. +#endif
  6008. +
  6009. +/* concatenating with "" ensures that only literal strings are accepted as argument
  6010. + * note that STR_WITH_LEN() can't be used as argument to macros or functions that
  6011. + * under some configurations might be macros
  6012. + */
  6013. +#ifndef STR_WITH_LEN
  6014. +# define STR_WITH_LEN(s) (s ""), (sizeof(s)-1)
  6015. +#endif
  6016. +#ifndef newSVpvs
  6017. +# define newSVpvs(str) newSVpvn(str "", sizeof(str) - 1)
  6018. +#endif
  6019. +
  6020. +#ifndef newSVpvs_flags
  6021. +# define newSVpvs_flags(str, flags) newSVpvn_flags(str "", sizeof(str) - 1, flags)
  6022. +#endif
  6023. +
  6024. +#ifndef newSVpvs_share
  6025. +# define newSVpvs_share(str) newSVpvn_share(str "", sizeof(str) - 1, 0)
  6026. +#endif
  6027. +
  6028. +#ifndef sv_catpvs
  6029. +# define sv_catpvs(sv, str) sv_catpvn(sv, str "", sizeof(str) - 1)
  6030. +#endif
  6031. +
  6032. +#ifndef sv_setpvs
  6033. +# define sv_setpvs(sv, str) sv_setpvn(sv, str "", sizeof(str) - 1)
  6034. +#endif
  6035. +
  6036. +#ifndef hv_fetchs
  6037. +# define hv_fetchs(hv, key, lval) hv_fetch(hv, key "", sizeof(key) - 1, lval)
  6038. +#endif
  6039. +
  6040. +#ifndef hv_stores
  6041. +# define hv_stores(hv, key, val) hv_store(hv, key "", sizeof(key) - 1, val, 0)
  6042. +#endif
  6043. +#ifndef gv_fetchpvs
  6044. +# define gv_fetchpvs(name, flags, svt) gv_fetchpvn_flags(name "", sizeof(name) - 1, flags, svt)
  6045. +#endif
  6046. +
  6047. +#ifndef gv_stashpvs
  6048. +# define gv_stashpvs(name, flags) gv_stashpvn(name "", sizeof(name) - 1, flags)
  6049. +#endif
  6050. +#ifndef get_cvs
  6051. +# define get_cvs(name, flags) get_cvn_flags(name "", sizeof(name)-1, flags)
  6052. +#endif
  6053. +#ifndef SvGETMAGIC
  6054. +# define SvGETMAGIC(x) STMT_START { if (SvGMAGICAL(x)) mg_get(x); } STMT_END
  6055. +#endif
  6056. +#ifndef PERL_MAGIC_sv
  6057. +# define PERL_MAGIC_sv '\0'
  6058. +#endif
  6059. +
  6060. +#ifndef PERL_MAGIC_overload
  6061. +# define PERL_MAGIC_overload 'A'
  6062. +#endif
  6063. +
  6064. +#ifndef PERL_MAGIC_overload_elem
  6065. +# define PERL_MAGIC_overload_elem 'a'
  6066. +#endif
  6067. +
  6068. +#ifndef PERL_MAGIC_overload_table
  6069. +# define PERL_MAGIC_overload_table 'c'
  6070. +#endif
  6071. +
  6072. +#ifndef PERL_MAGIC_bm
  6073. +# define PERL_MAGIC_bm 'B'
  6074. +#endif
  6075. +
  6076. +#ifndef PERL_MAGIC_regdata
  6077. +# define PERL_MAGIC_regdata 'D'
  6078. +#endif
  6079. +
  6080. +#ifndef PERL_MAGIC_regdatum
  6081. +# define PERL_MAGIC_regdatum 'd'
  6082. +#endif
  6083. +
  6084. +#ifndef PERL_MAGIC_env
  6085. +# define PERL_MAGIC_env 'E'
  6086. +#endif
  6087. +
  6088. +#ifndef PERL_MAGIC_envelem
  6089. +# define PERL_MAGIC_envelem 'e'
  6090. +#endif
  6091. +
  6092. +#ifndef PERL_MAGIC_fm
  6093. +# define PERL_MAGIC_fm 'f'
  6094. +#endif
  6095. +
  6096. +#ifndef PERL_MAGIC_regex_global
  6097. +# define PERL_MAGIC_regex_global 'g'
  6098. +#endif
  6099. +
  6100. +#ifndef PERL_MAGIC_isa
  6101. +# define PERL_MAGIC_isa 'I'
  6102. +#endif
  6103. +
  6104. +#ifndef PERL_MAGIC_isaelem
  6105. +# define PERL_MAGIC_isaelem 'i'
  6106. +#endif
  6107. +
  6108. +#ifndef PERL_MAGIC_nkeys
  6109. +# define PERL_MAGIC_nkeys 'k'
  6110. +#endif
  6111. +
  6112. +#ifndef PERL_MAGIC_dbfile
  6113. +# define PERL_MAGIC_dbfile 'L'
  6114. +#endif
  6115. +
  6116. +#ifndef PERL_MAGIC_dbline
  6117. +# define PERL_MAGIC_dbline 'l'
  6118. +#endif
  6119. +
  6120. +#ifndef PERL_MAGIC_mutex
  6121. +# define PERL_MAGIC_mutex 'm'
  6122. +#endif
  6123. +
  6124. +#ifndef PERL_MAGIC_shared
  6125. +# define PERL_MAGIC_shared 'N'
  6126. +#endif
  6127. +
  6128. +#ifndef PERL_MAGIC_shared_scalar
  6129. +# define PERL_MAGIC_shared_scalar 'n'
  6130. +#endif
  6131. +
  6132. +#ifndef PERL_MAGIC_collxfrm
  6133. +# define PERL_MAGIC_collxfrm 'o'
  6134. +#endif
  6135. +
  6136. +#ifndef PERL_MAGIC_tied
  6137. +# define PERL_MAGIC_tied 'P'
  6138. +#endif
  6139. +
  6140. +#ifndef PERL_MAGIC_tiedelem
  6141. +# define PERL_MAGIC_tiedelem 'p'
  6142. +#endif
  6143. +
  6144. +#ifndef PERL_MAGIC_tiedscalar
  6145. +# define PERL_MAGIC_tiedscalar 'q'
  6146. +#endif
  6147. +
  6148. +#ifndef PERL_MAGIC_qr
  6149. +# define PERL_MAGIC_qr 'r'
  6150. +#endif
  6151. +
  6152. +#ifndef PERL_MAGIC_sig
  6153. +# define PERL_MAGIC_sig 'S'
  6154. +#endif
  6155. +
  6156. +#ifndef PERL_MAGIC_sigelem
  6157. +# define PERL_MAGIC_sigelem 's'
  6158. +#endif
  6159. +
  6160. +#ifndef PERL_MAGIC_taint
  6161. +# define PERL_MAGIC_taint 't'
  6162. +#endif
  6163. +
  6164. +#ifndef PERL_MAGIC_uvar
  6165. +# define PERL_MAGIC_uvar 'U'
  6166. +#endif
  6167. +
  6168. +#ifndef PERL_MAGIC_uvar_elem
  6169. +# define PERL_MAGIC_uvar_elem 'u'
  6170. +#endif
  6171. +
  6172. +#ifndef PERL_MAGIC_vstring
  6173. +# define PERL_MAGIC_vstring 'V'
  6174. +#endif
  6175. +
  6176. +#ifndef PERL_MAGIC_vec
  6177. +# define PERL_MAGIC_vec 'v'
  6178. +#endif
  6179. +
  6180. +#ifndef PERL_MAGIC_utf8
  6181. +# define PERL_MAGIC_utf8 'w'
  6182. +#endif
  6183. +
  6184. +#ifndef PERL_MAGIC_substr
  6185. +# define PERL_MAGIC_substr 'x'
  6186. +#endif
  6187. +
  6188. +#ifndef PERL_MAGIC_defelem
  6189. +# define PERL_MAGIC_defelem 'y'
  6190. +#endif
  6191. +
  6192. +#ifndef PERL_MAGIC_glob
  6193. +# define PERL_MAGIC_glob '*'
  6194. +#endif
  6195. +
  6196. +#ifndef PERL_MAGIC_arylen
  6197. +# define PERL_MAGIC_arylen '#'
  6198. +#endif
  6199. +
  6200. +#ifndef PERL_MAGIC_pos
  6201. +# define PERL_MAGIC_pos '.'
  6202. +#endif
  6203. +
  6204. +#ifndef PERL_MAGIC_backref
  6205. +# define PERL_MAGIC_backref '<'
  6206. +#endif
  6207. +
  6208. +#ifndef PERL_MAGIC_ext
  6209. +# define PERL_MAGIC_ext '~'
  6210. +#endif
  6211. +
  6212. +/* That's the best we can do... */
  6213. +#ifndef sv_catpvn_nomg
  6214. +# define sv_catpvn_nomg sv_catpvn
  6215. +#endif
  6216. +
  6217. +#ifndef sv_catsv_nomg
  6218. +# define sv_catsv_nomg sv_catsv
  6219. +#endif
  6220. +
  6221. +#ifndef sv_setsv_nomg
  6222. +# define sv_setsv_nomg sv_setsv
  6223. +#endif
  6224. +
  6225. +#ifndef sv_pvn_nomg
  6226. +# define sv_pvn_nomg sv_pvn
  6227. +#endif
  6228. +
  6229. +#ifndef SvIV_nomg
  6230. +# define SvIV_nomg SvIV
  6231. +#endif
  6232. +
  6233. +#ifndef SvUV_nomg
  6234. +# define SvUV_nomg SvUV
  6235. +#endif
  6236. +
  6237. +#ifndef sv_catpv_mg
  6238. +# define sv_catpv_mg(sv, ptr) \
  6239. + STMT_START { \
  6240. + SV *TeMpSv = sv; \
  6241. + sv_catpv(TeMpSv,ptr); \
  6242. + SvSETMAGIC(TeMpSv); \
  6243. + } STMT_END
  6244. +#endif
  6245. +
  6246. +#ifndef sv_catpvn_mg
  6247. +# define sv_catpvn_mg(sv, ptr, len) \
  6248. + STMT_START { \
  6249. + SV *TeMpSv = sv; \
  6250. + sv_catpvn(TeMpSv,ptr,len); \
  6251. + SvSETMAGIC(TeMpSv); \
  6252. + } STMT_END
  6253. +#endif
  6254. +
  6255. +#ifndef sv_catsv_mg
  6256. +# define sv_catsv_mg(dsv, ssv) \
  6257. + STMT_START { \
  6258. + SV *TeMpSv = dsv; \
  6259. + sv_catsv(TeMpSv,ssv); \
  6260. + SvSETMAGIC(TeMpSv); \
  6261. + } STMT_END
  6262. +#endif
  6263. +
  6264. +#ifndef sv_setiv_mg
  6265. +# define sv_setiv_mg(sv, i) \
  6266. + STMT_START { \
  6267. + SV *TeMpSv = sv; \
  6268. + sv_setiv(TeMpSv,i); \
  6269. + SvSETMAGIC(TeMpSv); \
  6270. + } STMT_END
  6271. +#endif
  6272. +
  6273. +#ifndef sv_setnv_mg
  6274. +# define sv_setnv_mg(sv, num) \
  6275. + STMT_START { \
  6276. + SV *TeMpSv = sv; \
  6277. + sv_setnv(TeMpSv,num); \
  6278. + SvSETMAGIC(TeMpSv); \
  6279. + } STMT_END
  6280. +#endif
  6281. +
  6282. +#ifndef sv_setpv_mg
  6283. +# define sv_setpv_mg(sv, ptr) \
  6284. + STMT_START { \
  6285. + SV *TeMpSv = sv; \
  6286. + sv_setpv(TeMpSv,ptr); \
  6287. + SvSETMAGIC(TeMpSv); \
  6288. + } STMT_END
  6289. +#endif
  6290. +
  6291. +#ifndef sv_setpvn_mg
  6292. +# define sv_setpvn_mg(sv, ptr, len) \
  6293. + STMT_START { \
  6294. + SV *TeMpSv = sv; \
  6295. + sv_setpvn(TeMpSv,ptr,len); \
  6296. + SvSETMAGIC(TeMpSv); \
  6297. + } STMT_END
  6298. +#endif
  6299. +
  6300. +#ifndef sv_setsv_mg
  6301. +# define sv_setsv_mg(dsv, ssv) \
  6302. + STMT_START { \
  6303. + SV *TeMpSv = dsv; \
  6304. + sv_setsv(TeMpSv,ssv); \
  6305. + SvSETMAGIC(TeMpSv); \
  6306. + } STMT_END
  6307. +#endif
  6308. +
  6309. +#ifndef sv_setuv_mg
  6310. +# define sv_setuv_mg(sv, i) \
  6311. + STMT_START { \
  6312. + SV *TeMpSv = sv; \
  6313. + sv_setuv(TeMpSv,i); \
  6314. + SvSETMAGIC(TeMpSv); \
  6315. + } STMT_END
  6316. +#endif
  6317. +
  6318. +#ifndef sv_usepvn_mg
  6319. +# define sv_usepvn_mg(sv, ptr, len) \
  6320. + STMT_START { \
  6321. + SV *TeMpSv = sv; \
  6322. + sv_usepvn(TeMpSv,ptr,len); \
  6323. + SvSETMAGIC(TeMpSv); \
  6324. + } STMT_END
  6325. +#endif
  6326. +#ifndef SvVSTRING_mg
  6327. +# define SvVSTRING_mg(sv) (SvMAGICAL(sv) ? mg_find(sv, PERL_MAGIC_vstring) : NULL)
  6328. +#endif
  6329. +
  6330. +/* Hint: sv_magic_portable
  6331. + * This is a compatibility function that is only available with
  6332. + * Devel::PPPort. It is NOT in the perl core.
  6333. + * Its purpose is to mimic the 5.8.0 behaviour of sv_magic() when
  6334. + * it is being passed a name pointer with namlen == 0. In that
  6335. + * case, perl 5.8.0 and later store the pointer, not a copy of it.
  6336. + * The compatibility can be provided back to perl 5.004. With
  6337. + * earlier versions, the code will not compile.
  6338. + */
  6339. +
  6340. +#if (PERL_BCDVERSION < 0x5004000)
  6341. +
  6342. + /* code that uses sv_magic_portable will not compile */
  6343. +
  6344. +#elif (PERL_BCDVERSION < 0x5008000)
  6345. +
  6346. +# define sv_magic_portable(sv, obj, how, name, namlen) \
  6347. + STMT_START { \
  6348. + SV *SvMp_sv = (sv); \
  6349. + char *SvMp_name = (char *) (name); \
  6350. + I32 SvMp_namlen = (namlen); \
  6351. + if (SvMp_name && SvMp_namlen == 0) \
  6352. + { \
  6353. + MAGIC *mg; \
  6354. + sv_magic(SvMp_sv, obj, how, 0, 0); \
  6355. + mg = SvMAGIC(SvMp_sv); \
  6356. + mg->mg_len = -42; /* XXX: this is the tricky part */ \
  6357. + mg->mg_ptr = SvMp_name; \
  6358. + } \
  6359. + else \
  6360. + { \
  6361. + sv_magic(SvMp_sv, obj, how, SvMp_name, SvMp_namlen); \
  6362. + } \
  6363. + } STMT_END
  6364. +
  6365. +#else
  6366. +
  6367. +# define sv_magic_portable(a, b, c, d, e) sv_magic(a, b, c, d, e)
  6368. +
  6369. +#endif
  6370. +
  6371. +#ifdef USE_ITHREADS
  6372. +#ifndef CopFILE
  6373. +# define CopFILE(c) ((c)->cop_file)
  6374. +#endif
  6375. +
  6376. +#ifndef CopFILEGV
  6377. +# define CopFILEGV(c) (CopFILE(c) ? gv_fetchfile(CopFILE(c)) : Nullgv)
  6378. +#endif
  6379. +
  6380. +#ifndef CopFILE_set
  6381. +# define CopFILE_set(c,pv) ((c)->cop_file = savepv(pv))
  6382. +#endif
  6383. +
  6384. +#ifndef CopFILESV
  6385. +# define CopFILESV(c) (CopFILE(c) ? GvSV(gv_fetchfile(CopFILE(c))) : Nullsv)
  6386. +#endif
  6387. +
  6388. +#ifndef CopFILEAV
  6389. +# define CopFILEAV(c) (CopFILE(c) ? GvAV(gv_fetchfile(CopFILE(c))) : Nullav)
  6390. +#endif
  6391. +
  6392. +#ifndef CopSTASHPV
  6393. +# define CopSTASHPV(c) ((c)->cop_stashpv)
  6394. +#endif
  6395. +
  6396. +#ifndef CopSTASHPV_set
  6397. +# define CopSTASHPV_set(c,pv) ((c)->cop_stashpv = ((pv) ? savepv(pv) : Nullch))
  6398. +#endif
  6399. +
  6400. +#ifndef CopSTASH
  6401. +# define CopSTASH(c) (CopSTASHPV(c) ? gv_stashpv(CopSTASHPV(c),GV_ADD) : Nullhv)
  6402. +#endif
  6403. +
  6404. +#ifndef CopSTASH_set
  6405. +# define CopSTASH_set(c,hv) CopSTASHPV_set(c, (hv) ? HvNAME(hv) : Nullch)
  6406. +#endif
  6407. +
  6408. +#ifndef CopSTASH_eq
  6409. +# define CopSTASH_eq(c,hv) ((hv) && (CopSTASHPV(c) == HvNAME(hv) \
  6410. + || (CopSTASHPV(c) && HvNAME(hv) \
  6411. + && strEQ(CopSTASHPV(c), HvNAME(hv)))))
  6412. +#endif
  6413. +
  6414. +#else
  6415. +#ifndef CopFILEGV
  6416. +# define CopFILEGV(c) ((c)->cop_filegv)
  6417. +#endif
  6418. +
  6419. +#ifndef CopFILEGV_set
  6420. +# define CopFILEGV_set(c,gv) ((c)->cop_filegv = (GV*)SvREFCNT_inc(gv))
  6421. +#endif
  6422. +
  6423. +#ifndef CopFILE_set
  6424. +# define CopFILE_set(c,pv) CopFILEGV_set((c), gv_fetchfile(pv))
  6425. +#endif
  6426. +
  6427. +#ifndef CopFILESV
  6428. +# define CopFILESV(c) (CopFILEGV(c) ? GvSV(CopFILEGV(c)) : Nullsv)
  6429. +#endif
  6430. +
  6431. +#ifndef CopFILEAV
  6432. +# define CopFILEAV(c) (CopFILEGV(c) ? GvAV(CopFILEGV(c)) : Nullav)
  6433. +#endif
  6434. +
  6435. +#ifndef CopFILE
  6436. +# define CopFILE(c) (CopFILESV(c) ? SvPVX(CopFILESV(c)) : Nullch)
  6437. +#endif
  6438. +
  6439. +#ifndef CopSTASH
  6440. +# define CopSTASH(c) ((c)->cop_stash)
  6441. +#endif
  6442. +
  6443. +#ifndef CopSTASH_set
  6444. +# define CopSTASH_set(c,hv) ((c)->cop_stash = (hv))
  6445. +#endif
  6446. +
  6447. +#ifndef CopSTASHPV
  6448. +# define CopSTASHPV(c) (CopSTASH(c) ? HvNAME(CopSTASH(c)) : Nullch)
  6449. +#endif
  6450. +
  6451. +#ifndef CopSTASHPV_set
  6452. +# define CopSTASHPV_set(c,pv) CopSTASH_set((c), gv_stashpv(pv,GV_ADD))
  6453. +#endif
  6454. +
  6455. +#ifndef CopSTASH_eq
  6456. +# define CopSTASH_eq(c,hv) (CopSTASH(c) == (hv))
  6457. +#endif
  6458. +
  6459. +#endif /* USE_ITHREADS */
  6460. +#ifndef IN_PERL_COMPILETIME
  6461. +# define IN_PERL_COMPILETIME (PL_curcop == &PL_compiling)
  6462. +#endif
  6463. +
  6464. +#ifndef IN_LOCALE_RUNTIME
  6465. +# define IN_LOCALE_RUNTIME (PL_curcop->op_private & HINT_LOCALE)
  6466. +#endif
  6467. +
  6468. +#ifndef IN_LOCALE_COMPILETIME
  6469. +# define IN_LOCALE_COMPILETIME (PL_hints & HINT_LOCALE)
  6470. +#endif
  6471. +
  6472. +#ifndef IN_LOCALE
  6473. +# define IN_LOCALE (IN_PERL_COMPILETIME ? IN_LOCALE_COMPILETIME : IN_LOCALE_RUNTIME)
  6474. +#endif
  6475. +#ifndef IS_NUMBER_IN_UV
  6476. +# define IS_NUMBER_IN_UV 0x01
  6477. +#endif
  6478. +
  6479. +#ifndef IS_NUMBER_GREATER_THAN_UV_MAX
  6480. +# define IS_NUMBER_GREATER_THAN_UV_MAX 0x02
  6481. +#endif
  6482. +
  6483. +#ifndef IS_NUMBER_NOT_INT
  6484. +# define IS_NUMBER_NOT_INT 0x04
  6485. +#endif
  6486. +
  6487. +#ifndef IS_NUMBER_NEG
  6488. +# define IS_NUMBER_NEG 0x08
  6489. +#endif
  6490. +
  6491. +#ifndef IS_NUMBER_INFINITY
  6492. +# define IS_NUMBER_INFINITY 0x10
  6493. +#endif
  6494. +
  6495. +#ifndef IS_NUMBER_NAN
  6496. +# define IS_NUMBER_NAN 0x20
  6497. +#endif
  6498. +#ifndef GROK_NUMERIC_RADIX
  6499. +# define GROK_NUMERIC_RADIX(sp, send) grok_numeric_radix(sp, send)
  6500. +#endif
  6501. +#ifndef PERL_SCAN_GREATER_THAN_UV_MAX
  6502. +# define PERL_SCAN_GREATER_THAN_UV_MAX 0x02
  6503. +#endif
  6504. +
  6505. +#ifndef PERL_SCAN_SILENT_ILLDIGIT
  6506. +# define PERL_SCAN_SILENT_ILLDIGIT 0x04
  6507. +#endif
  6508. +
  6509. +#ifndef PERL_SCAN_ALLOW_UNDERSCORES
  6510. +# define PERL_SCAN_ALLOW_UNDERSCORES 0x01
  6511. +#endif
  6512. +
  6513. +#ifndef PERL_SCAN_DISALLOW_PREFIX
  6514. +# define PERL_SCAN_DISALLOW_PREFIX 0x02
  6515. +#endif
  6516. +
  6517. +#ifndef grok_numeric_radix
  6518. +#if defined(NEED_grok_numeric_radix)
  6519. +static bool DPPP_(my_grok_numeric_radix)(pTHX_ const char ** sp, const char * send);
  6520. +static
  6521. +#else
  6522. +extern bool DPPP_(my_grok_numeric_radix)(pTHX_ const char ** sp, const char * send);
  6523. +#endif
  6524. +
  6525. +#ifdef grok_numeric_radix
  6526. +# undef grok_numeric_radix
  6527. +#endif
  6528. +#define grok_numeric_radix(a,b) DPPP_(my_grok_numeric_radix)(aTHX_ a,b)
  6529. +#define Perl_grok_numeric_radix DPPP_(my_grok_numeric_radix)
  6530. +
  6531. +#if defined(NEED_grok_numeric_radix) || defined(NEED_grok_numeric_radix_GLOBAL)
  6532. +bool
  6533. +DPPP_(my_grok_numeric_radix)(pTHX_ const char **sp, const char *send)
  6534. +{
  6535. +#ifdef USE_LOCALE_NUMERIC
  6536. +#ifdef PL_numeric_radix_sv
  6537. + if (PL_numeric_radix_sv && IN_LOCALE) {
  6538. + STRLEN len;
  6539. + char* radix = SvPV(PL_numeric_radix_sv, len);
  6540. + if (*sp + len <= send && memEQ(*sp, radix, len)) {
  6541. + *sp += len;
  6542. + return TRUE;
  6543. + }
  6544. + }
  6545. +#else
  6546. + /* older perls don't have PL_numeric_radix_sv so the radix
  6547. + * must manually be requested from locale.h
  6548. + */
  6549. +#include <locale.h>
  6550. + dTHR; /* needed for older threaded perls */
  6551. + struct lconv *lc = localeconv();
  6552. + char *radix = lc->decimal_point;
  6553. + if (radix && IN_LOCALE) {
  6554. + STRLEN len = strlen(radix);
  6555. + if (*sp + len <= send && memEQ(*sp, radix, len)) {
  6556. + *sp += len;
  6557. + return TRUE;
  6558. + }
  6559. + }
  6560. +#endif
  6561. +#endif /* USE_LOCALE_NUMERIC */
  6562. + /* always try "." if numeric radix didn't match because
  6563. + * we may have data from different locales mixed */
  6564. + if (*sp < send && **sp == '.') {
  6565. + ++*sp;
  6566. + return TRUE;
  6567. + }
  6568. + return FALSE;
  6569. +}
  6570. +#endif
  6571. +#endif
  6572. +
  6573. +#ifndef grok_number
  6574. +#if defined(NEED_grok_number)
  6575. +static int DPPP_(my_grok_number)(pTHX_ const char * pv, STRLEN len, UV * valuep);
  6576. +static
  6577. +#else
  6578. +extern int DPPP_(my_grok_number)(pTHX_ const char * pv, STRLEN len, UV * valuep);
  6579. +#endif
  6580. +
  6581. +#ifdef grok_number
  6582. +# undef grok_number
  6583. +#endif
  6584. +#define grok_number(a,b,c) DPPP_(my_grok_number)(aTHX_ a,b,c)
  6585. +#define Perl_grok_number DPPP_(my_grok_number)
  6586. +
  6587. +#if defined(NEED_grok_number) || defined(NEED_grok_number_GLOBAL)
  6588. +int
  6589. +DPPP_(my_grok_number)(pTHX_ const char *pv, STRLEN len, UV *valuep)
  6590. +{
  6591. + const char *s = pv;
  6592. + const char *send = pv + len;
  6593. + const UV max_div_10 = UV_MAX / 10;
  6594. + const char max_mod_10 = UV_MAX % 10;
  6595. + int numtype = 0;
  6596. + int sawinf = 0;
  6597. + int sawnan = 0;
  6598. +
  6599. + while (s < send && isSPACE(*s))
  6600. + s++;
  6601. + if (s == send) {
  6602. + return 0;
  6603. + } else if (*s == '-') {
  6604. + s++;
  6605. + numtype = IS_NUMBER_NEG;
  6606. + }
  6607. + else if (*s == '+')
  6608. + s++;
  6609. +
  6610. + if (s == send)
  6611. + return 0;
  6612. +
  6613. + /* next must be digit or the radix separator or beginning of infinity */
  6614. + if (isDIGIT(*s)) {
  6615. + /* UVs are at least 32 bits, so the first 9 decimal digits cannot
  6616. + overflow. */
  6617. + UV value = *s - '0';
  6618. + /* This construction seems to be more optimiser friendly.
  6619. + (without it gcc does the isDIGIT test and the *s - '0' separately)
  6620. + With it gcc on arm is managing 6 instructions (6 cycles) per digit.
  6621. + In theory the optimiser could deduce how far to unroll the loop
  6622. + before checking for overflow. */
  6623. + if (++s < send) {
  6624. + int digit = *s - '0';
  6625. + if (digit >= 0 && digit <= 9) {
  6626. + value = value * 10 + digit;
  6627. + if (++s < send) {
  6628. + digit = *s - '0';
  6629. + if (digit >= 0 && digit <= 9) {
  6630. + value = value * 10 + digit;
  6631. + if (++s < send) {
  6632. + digit = *s - '0';
  6633. + if (digit >= 0 && digit <= 9) {
  6634. + value = value * 10 + digit;
  6635. + if (++s < send) {
  6636. + digit = *s - '0';
  6637. + if (digit >= 0 && digit <= 9) {
  6638. + value = value * 10 + digit;
  6639. + if (++s < send) {
  6640. + digit = *s - '0';
  6641. + if (digit >= 0 && digit <= 9) {
  6642. + value = value * 10 + digit;
  6643. + if (++s < send) {
  6644. + digit = *s - '0';
  6645. + if (digit >= 0 && digit <= 9) {
  6646. + value = value * 10 + digit;
  6647. + if (++s < send) {
  6648. + digit = *s - '0';
  6649. + if (digit >= 0 && digit <= 9) {
  6650. + value = value * 10 + digit;
  6651. + if (++s < send) {
  6652. + digit = *s - '0';
  6653. + if (digit >= 0 && digit <= 9) {
  6654. + value = value * 10 + digit;
  6655. + if (++s < send) {
  6656. + /* Now got 9 digits, so need to check
  6657. + each time for overflow. */
  6658. + digit = *s - '0';
  6659. + while (digit >= 0 && digit <= 9
  6660. + && (value < max_div_10
  6661. + || (value == max_div_10
  6662. + && digit <= max_mod_10))) {
  6663. + value = value * 10 + digit;
  6664. + if (++s < send)
  6665. + digit = *s - '0';
  6666. + else
  6667. + break;
  6668. + }
  6669. + if (digit >= 0 && digit <= 9
  6670. + && (s < send)) {
  6671. + /* value overflowed.
  6672. + skip the remaining digits, don't
  6673. + worry about setting *valuep. */
  6674. + do {
  6675. + s++;
  6676. + } while (s < send && isDIGIT(*s));
  6677. + numtype |=
  6678. + IS_NUMBER_GREATER_THAN_UV_MAX;
  6679. + goto skip_value;
  6680. + }
  6681. + }
  6682. + }
  6683. + }
  6684. + }
  6685. + }
  6686. + }
  6687. + }
  6688. + }
  6689. + }
  6690. + }
  6691. + }
  6692. + }
  6693. + }
  6694. + }
  6695. + }
  6696. + }
  6697. + }
  6698. + numtype |= IS_NUMBER_IN_UV;
  6699. + if (valuep)
  6700. + *valuep = value;
  6701. +
  6702. + skip_value:
  6703. + if (GROK_NUMERIC_RADIX(&s, send)) {
  6704. + numtype |= IS_NUMBER_NOT_INT;
  6705. + while (s < send && isDIGIT(*s)) /* optional digits after the radix */
  6706. + s++;
  6707. + }
  6708. + }
  6709. + else if (GROK_NUMERIC_RADIX(&s, send)) {
  6710. + numtype |= IS_NUMBER_NOT_INT | IS_NUMBER_IN_UV; /* valuep assigned below */
  6711. + /* no digits before the radix means we need digits after it */
  6712. + if (s < send && isDIGIT(*s)) {
  6713. + do {
  6714. + s++;
  6715. + } while (s < send && isDIGIT(*s));
  6716. + if (valuep) {
  6717. + /* integer approximation is valid - it's 0. */
  6718. + *valuep = 0;
  6719. + }
  6720. + }
  6721. + else
  6722. + return 0;
  6723. + } else if (*s == 'I' || *s == 'i') {
  6724. + s++; if (s == send || (*s != 'N' && *s != 'n')) return 0;
  6725. + s++; if (s == send || (*s != 'F' && *s != 'f')) return 0;
  6726. + s++; if (s < send && (*s == 'I' || *s == 'i')) {
  6727. + s++; if (s == send || (*s != 'N' && *s != 'n')) return 0;
  6728. + s++; if (s == send || (*s != 'I' && *s != 'i')) return 0;
  6729. + s++; if (s == send || (*s != 'T' && *s != 't')) return 0;
  6730. + s++; if (s == send || (*s != 'Y' && *s != 'y')) return 0;
  6731. + s++;
  6732. + }
  6733. + sawinf = 1;
  6734. + } else if (*s == 'N' || *s == 'n') {
  6735. + /* XXX TODO: There are signaling NaNs and quiet NaNs. */
  6736. + s++; if (s == send || (*s != 'A' && *s != 'a')) return 0;
  6737. + s++; if (s == send || (*s != 'N' && *s != 'n')) return 0;
  6738. + s++;
  6739. + sawnan = 1;
  6740. + } else
  6741. + return 0;
  6742. +
  6743. + if (sawinf) {
  6744. + numtype &= IS_NUMBER_NEG; /* Keep track of sign */
  6745. + numtype |= IS_NUMBER_INFINITY | IS_NUMBER_NOT_INT;
  6746. + } else if (sawnan) {
  6747. + numtype &= IS_NUMBER_NEG; /* Keep track of sign */
  6748. + numtype |= IS_NUMBER_NAN | IS_NUMBER_NOT_INT;
  6749. + } else if (s < send) {
  6750. + /* we can have an optional exponent part */
  6751. + if (*s == 'e' || *s == 'E') {
  6752. + /* The only flag we keep is sign. Blow away any "it's UV" */
  6753. + numtype &= IS_NUMBER_NEG;
  6754. + numtype |= IS_NUMBER_NOT_INT;
  6755. + s++;
  6756. + if (s < send && (*s == '-' || *s == '+'))
  6757. + s++;
  6758. + if (s < send && isDIGIT(*s)) {
  6759. + do {
  6760. + s++;
  6761. + } while (s < send && isDIGIT(*s));
  6762. + }
  6763. + else
  6764. + return 0;
  6765. + }
  6766. + }
  6767. + while (s < send && isSPACE(*s))
  6768. + s++;
  6769. + if (s >= send)
  6770. + return numtype;
  6771. + if (len == 10 && memEQ(pv, "0 but true", 10)) {
  6772. + if (valuep)
  6773. + *valuep = 0;
  6774. + return IS_NUMBER_IN_UV;
  6775. + }
  6776. + return 0;
  6777. +}
  6778. +#endif
  6779. +#endif
  6780. +
  6781. +/*
  6782. + * The grok_* routines have been modified to use warn() instead of
  6783. + * Perl_warner(). Also, 'hexdigit' was the former name of PL_hexdigit,
  6784. + * which is why the stack variable has been renamed to 'xdigit'.
  6785. + */
  6786. +
  6787. +#ifndef grok_bin
  6788. +#if defined(NEED_grok_bin)
  6789. +static UV DPPP_(my_grok_bin)(pTHX_ const char * start, STRLEN * len_p, I32 * flags, NV * result);
  6790. +static
  6791. +#else
  6792. +extern UV DPPP_(my_grok_bin)(pTHX_ const char * start, STRLEN * len_p, I32 * flags, NV * result);
  6793. +#endif
  6794. +
  6795. +#ifdef grok_bin
  6796. +# undef grok_bin
  6797. +#endif
  6798. +#define grok_bin(a,b,c,d) DPPP_(my_grok_bin)(aTHX_ a,b,c,d)
  6799. +#define Perl_grok_bin DPPP_(my_grok_bin)
  6800. +
  6801. +#if defined(NEED_grok_bin) || defined(NEED_grok_bin_GLOBAL)
  6802. +UV
  6803. +DPPP_(my_grok_bin)(pTHX_ const char *start, STRLEN *len_p, I32 *flags, NV *result)
  6804. +{
  6805. + const char *s = start;
  6806. + STRLEN len = *len_p;
  6807. + UV value = 0;
  6808. + NV value_nv = 0;
  6809. +
  6810. + const UV max_div_2 = UV_MAX / 2;
  6811. + bool allow_underscores = *flags & PERL_SCAN_ALLOW_UNDERSCORES;
  6812. + bool overflowed = FALSE;
  6813. +
  6814. + if (!(*flags & PERL_SCAN_DISALLOW_PREFIX)) {
  6815. + /* strip off leading b or 0b.
  6816. + for compatibility silently suffer "b" and "0b" as valid binary
  6817. + numbers. */
  6818. + if (len >= 1) {
  6819. + if (s[0] == 'b') {
  6820. + s++;
  6821. + len--;
  6822. + }
  6823. + else if (len >= 2 && s[0] == '0' && s[1] == 'b') {
  6824. + s+=2;
  6825. + len-=2;
  6826. + }
  6827. + }
  6828. + }
  6829. +
  6830. + for (; len-- && *s; s++) {
  6831. + char bit = *s;
  6832. + if (bit == '0' || bit == '1') {
  6833. + /* Write it in this wonky order with a goto to attempt to get the
  6834. + compiler to make the common case integer-only loop pretty tight.
  6835. + With gcc seems to be much straighter code than old scan_bin. */
  6836. + redo:
  6837. + if (!overflowed) {
  6838. + if (value <= max_div_2) {
  6839. + value = (value << 1) | (bit - '0');
  6840. + continue;
  6841. + }
  6842. + /* Bah. We're just overflowed. */
  6843. + warn("Integer overflow in binary number");
  6844. + overflowed = TRUE;
  6845. + value_nv = (NV) value;
  6846. + }
  6847. + value_nv *= 2.0;
  6848. + /* If an NV has not enough bits in its mantissa to
  6849. + * represent a UV this summing of small low-order numbers
  6850. + * is a waste of time (because the NV cannot preserve
  6851. + * the low-order bits anyway): we could just remember when
  6852. + * did we overflow and in the end just multiply value_nv by the
  6853. + * right amount. */
  6854. + value_nv += (NV)(bit - '0');
  6855. + continue;
  6856. + }
  6857. + if (bit == '_' && len && allow_underscores && (bit = s[1])
  6858. + && (bit == '0' || bit == '1'))
  6859. + {
  6860. + --len;
  6861. + ++s;
  6862. + goto redo;
  6863. + }
  6864. + if (!(*flags & PERL_SCAN_SILENT_ILLDIGIT))
  6865. + warn("Illegal binary digit '%c' ignored", *s);
  6866. + break;
  6867. + }
  6868. +
  6869. + if ( ( overflowed && value_nv > 4294967295.0)
  6870. +#if UVSIZE > 4
  6871. + || (!overflowed && value > 0xffffffff )
  6872. +#endif
  6873. + ) {
  6874. + warn("Binary number > 0b11111111111111111111111111111111 non-portable");
  6875. + }
  6876. + *len_p = s - start;
  6877. + if (!overflowed) {
  6878. + *flags = 0;
  6879. + return value;
  6880. + }
  6881. + *flags = PERL_SCAN_GREATER_THAN_UV_MAX;
  6882. + if (result)
  6883. + *result = value_nv;
  6884. + return UV_MAX;
  6885. +}
  6886. +#endif
  6887. +#endif
  6888. +
  6889. +#ifndef grok_hex
  6890. +#if defined(NEED_grok_hex)
  6891. +static UV DPPP_(my_grok_hex)(pTHX_ const char * start, STRLEN * len_p, I32 * flags, NV * result);
  6892. +static
  6893. +#else
  6894. +extern UV DPPP_(my_grok_hex)(pTHX_ const char * start, STRLEN * len_p, I32 * flags, NV * result);
  6895. +#endif
  6896. +
  6897. +#ifdef grok_hex
  6898. +# undef grok_hex
  6899. +#endif
  6900. +#define grok_hex(a,b,c,d) DPPP_(my_grok_hex)(aTHX_ a,b,c,d)
  6901. +#define Perl_grok_hex DPPP_(my_grok_hex)
  6902. +
  6903. +#if defined(NEED_grok_hex) || defined(NEED_grok_hex_GLOBAL)
  6904. +UV
  6905. +DPPP_(my_grok_hex)(pTHX_ const char *start, STRLEN *len_p, I32 *flags, NV *result)
  6906. +{
  6907. + const char *s = start;
  6908. + STRLEN len = *len_p;
  6909. + UV value = 0;
  6910. + NV value_nv = 0;
  6911. +
  6912. + const UV max_div_16 = UV_MAX / 16;
  6913. + bool allow_underscores = *flags & PERL_SCAN_ALLOW_UNDERSCORES;
  6914. + bool overflowed = FALSE;
  6915. + const char *xdigit;
  6916. +
  6917. + if (!(*flags & PERL_SCAN_DISALLOW_PREFIX)) {
  6918. + /* strip off leading x or 0x.
  6919. + for compatibility silently suffer "x" and "0x" as valid hex numbers.
  6920. + */
  6921. + if (len >= 1) {
  6922. + if (s[0] == 'x') {
  6923. + s++;
  6924. + len--;
  6925. + }
  6926. + else if (len >= 2 && s[0] == '0' && s[1] == 'x') {
  6927. + s+=2;
  6928. + len-=2;
  6929. + }
  6930. + }
  6931. + }
  6932. +
  6933. + for (; len-- && *s; s++) {
  6934. + xdigit = strchr((char *) PL_hexdigit, *s);
  6935. + if (xdigit) {
  6936. + /* Write it in this wonky order with a goto to attempt to get the
  6937. + compiler to make the common case integer-only loop pretty tight.
  6938. + With gcc seems to be much straighter code than old scan_hex. */
  6939. + redo:
  6940. + if (!overflowed) {
  6941. + if (value <= max_div_16) {
  6942. + value = (value << 4) | ((xdigit - PL_hexdigit) & 15);
  6943. + continue;
  6944. + }
  6945. + warn("Integer overflow in hexadecimal number");
  6946. + overflowed = TRUE;
  6947. + value_nv = (NV) value;
  6948. + }
  6949. + value_nv *= 16.0;
  6950. + /* If an NV has not enough bits in its mantissa to
  6951. + * represent a UV this summing of small low-order numbers
  6952. + * is a waste of time (because the NV cannot preserve
  6953. + * the low-order bits anyway): we could just remember when
  6954. + * did we overflow and in the end just multiply value_nv by the
  6955. + * right amount of 16-tuples. */
  6956. + value_nv += (NV)((xdigit - PL_hexdigit) & 15);
  6957. + continue;
  6958. + }
  6959. + if (*s == '_' && len && allow_underscores && s[1]
  6960. + && (xdigit = strchr((char *) PL_hexdigit, s[1])))
  6961. + {
  6962. + --len;
  6963. + ++s;
  6964. + goto redo;
  6965. + }
  6966. + if (!(*flags & PERL_SCAN_SILENT_ILLDIGIT))
  6967. + warn("Illegal hexadecimal digit '%c' ignored", *s);
  6968. + break;
  6969. + }
  6970. +
  6971. + if ( ( overflowed && value_nv > 4294967295.0)
  6972. +#if UVSIZE > 4
  6973. + || (!overflowed && value > 0xffffffff )
  6974. +#endif
  6975. + ) {
  6976. + warn("Hexadecimal number > 0xffffffff non-portable");
  6977. + }
  6978. + *len_p = s - start;
  6979. + if (!overflowed) {
  6980. + *flags = 0;
  6981. + return value;
  6982. + }
  6983. + *flags = PERL_SCAN_GREATER_THAN_UV_MAX;
  6984. + if (result)
  6985. + *result = value_nv;
  6986. + return UV_MAX;
  6987. +}
  6988. +#endif
  6989. +#endif
  6990. +
  6991. +#ifndef grok_oct
  6992. +#if defined(NEED_grok_oct)
  6993. +static UV DPPP_(my_grok_oct)(pTHX_ const char * start, STRLEN * len_p, I32 * flags, NV * result);
  6994. +static
  6995. +#else
  6996. +extern UV DPPP_(my_grok_oct)(pTHX_ const char * start, STRLEN * len_p, I32 * flags, NV * result);
  6997. +#endif
  6998. +
  6999. +#ifdef grok_oct
  7000. +# undef grok_oct
  7001. +#endif
  7002. +#define grok_oct(a,b,c,d) DPPP_(my_grok_oct)(aTHX_ a,b,c,d)
  7003. +#define Perl_grok_oct DPPP_(my_grok_oct)
  7004. +
  7005. +#if defined(NEED_grok_oct) || defined(NEED_grok_oct_GLOBAL)
  7006. +UV
  7007. +DPPP_(my_grok_oct)(pTHX_ const char *start, STRLEN *len_p, I32 *flags, NV *result)
  7008. +{
  7009. + const char *s = start;
  7010. + STRLEN len = *len_p;
  7011. + UV value = 0;
  7012. + NV value_nv = 0;
  7013. +
  7014. + const UV max_div_8 = UV_MAX / 8;
  7015. + bool allow_underscores = *flags & PERL_SCAN_ALLOW_UNDERSCORES;
  7016. + bool overflowed = FALSE;
  7017. +
  7018. + for (; len-- && *s; s++) {
  7019. + /* gcc 2.95 optimiser not smart enough to figure that this subtraction
  7020. + out front allows slicker code. */
  7021. + int digit = *s - '0';
  7022. + if (digit >= 0 && digit <= 7) {
  7023. + /* Write it in this wonky order with a goto to attempt to get the
  7024. + compiler to make the common case integer-only loop pretty tight.
  7025. + */
  7026. + redo:
  7027. + if (!overflowed) {
  7028. + if (value <= max_div_8) {
  7029. + value = (value << 3) | digit;
  7030. + continue;
  7031. + }
  7032. + /* Bah. We're just overflowed. */
  7033. + warn("Integer overflow in octal number");
  7034. + overflowed = TRUE;
  7035. + value_nv = (NV) value;
  7036. + }
  7037. + value_nv *= 8.0;
  7038. + /* If an NV has not enough bits in its mantissa to
  7039. + * represent a UV this summing of small low-order numbers
  7040. + * is a waste of time (because the NV cannot preserve
  7041. + * the low-order bits anyway): we could just remember when
  7042. + * did we overflow and in the end just multiply value_nv by the
  7043. + * right amount of 8-tuples. */
  7044. + value_nv += (NV)digit;
  7045. + continue;
  7046. + }
  7047. + if (digit == ('_' - '0') && len && allow_underscores
  7048. + && (digit = s[1] - '0') && (digit >= 0 && digit <= 7))
  7049. + {
  7050. + --len;
  7051. + ++s;
  7052. + goto redo;
  7053. + }
  7054. + /* Allow \octal to work the DWIM way (that is, stop scanning
  7055. + * as soon as non-octal characters are seen, complain only iff
  7056. + * someone seems to want to use the digits eight and nine). */
  7057. + if (digit == 8 || digit == 9) {
  7058. + if (!(*flags & PERL_SCAN_SILENT_ILLDIGIT))
  7059. + warn("Illegal octal digit '%c' ignored", *s);
  7060. + }
  7061. + break;
  7062. + }
  7063. +
  7064. + if ( ( overflowed && value_nv > 4294967295.0)
  7065. +#if UVSIZE > 4
  7066. + || (!overflowed && value > 0xffffffff )
  7067. +#endif
  7068. + ) {
  7069. + warn("Octal number > 037777777777 non-portable");
  7070. + }
  7071. + *len_p = s - start;
  7072. + if (!overflowed) {
  7073. + *flags = 0;
  7074. + return value;
  7075. + }
  7076. + *flags = PERL_SCAN_GREATER_THAN_UV_MAX;
  7077. + if (result)
  7078. + *result = value_nv;
  7079. + return UV_MAX;
  7080. +}
  7081. +#endif
  7082. +#endif
  7083. +
  7084. +#if !defined(my_snprintf)
  7085. +#if defined(NEED_my_snprintf)
  7086. +static int DPPP_(my_my_snprintf)(char * buffer, const Size_t len, const char * format, ...);
  7087. +static
  7088. +#else
  7089. +extern int DPPP_(my_my_snprintf)(char * buffer, const Size_t len, const char * format, ...);
  7090. +#endif
  7091. +
  7092. +#define my_snprintf DPPP_(my_my_snprintf)
  7093. +#define Perl_my_snprintf DPPP_(my_my_snprintf)
  7094. +
  7095. +#if defined(NEED_my_snprintf) || defined(NEED_my_snprintf_GLOBAL)
  7096. +
  7097. +int
  7098. +DPPP_(my_my_snprintf)(char *buffer, const Size_t len, const char *format, ...)
  7099. +{
  7100. + dTHX;
  7101. + int retval;
  7102. + va_list ap;
  7103. + va_start(ap, format);
  7104. +#ifdef HAS_VSNPRINTF
  7105. + retval = vsnprintf(buffer, len, format, ap);
  7106. +#else
  7107. + retval = vsprintf(buffer, format, ap);
  7108. +#endif
  7109. + va_end(ap);
  7110. + if (retval < 0 || (len > 0 && (Size_t)retval >= len))
  7111. + Perl_croak(aTHX_ "panic: my_snprintf buffer overflow");
  7112. + return retval;
  7113. +}
  7114. +
  7115. +#endif
  7116. +#endif
  7117. +
  7118. +#if !defined(my_sprintf)
  7119. +#if defined(NEED_my_sprintf)
  7120. +static int DPPP_(my_my_sprintf)(char * buffer, const char * pat, ...);
  7121. +static
  7122. +#else
  7123. +extern int DPPP_(my_my_sprintf)(char * buffer, const char * pat, ...);
  7124. +#endif
  7125. +
  7126. +#define my_sprintf DPPP_(my_my_sprintf)
  7127. +#define Perl_my_sprintf DPPP_(my_my_sprintf)
  7128. +
  7129. +#if defined(NEED_my_sprintf) || defined(NEED_my_sprintf_GLOBAL)
  7130. +
  7131. +int
  7132. +DPPP_(my_my_sprintf)(char *buffer, const char* pat, ...)
  7133. +{
  7134. + va_list args;
  7135. + va_start(args, pat);
  7136. + vsprintf(buffer, pat, args);
  7137. + va_end(args);
  7138. + return strlen(buffer);
  7139. +}
  7140. +
  7141. +#endif
  7142. +#endif
  7143. +
  7144. +#ifdef NO_XSLOCKS
  7145. +# ifdef dJMPENV
  7146. +# define dXCPT dJMPENV; int rEtV = 0
  7147. +# define XCPT_TRY_START JMPENV_PUSH(rEtV); if (rEtV == 0)
  7148. +# define XCPT_TRY_END JMPENV_POP;
  7149. +# define XCPT_CATCH if (rEtV != 0)
  7150. +# define XCPT_RETHROW JMPENV_JUMP(rEtV)
  7151. +# else
  7152. +# define dXCPT Sigjmp_buf oldTOP; int rEtV = 0
  7153. +# define XCPT_TRY_START Copy(top_env, oldTOP, 1, Sigjmp_buf); rEtV = Sigsetjmp(top_env, 1); if (rEtV == 0)
  7154. +# define XCPT_TRY_END Copy(oldTOP, top_env, 1, Sigjmp_buf);
  7155. +# define XCPT_CATCH if (rEtV != 0)
  7156. +# define XCPT_RETHROW Siglongjmp(top_env, rEtV)
  7157. +# endif
  7158. +#endif
  7159. +
  7160. +#if !defined(my_strlcat)
  7161. +#if defined(NEED_my_strlcat)
  7162. +static Size_t DPPP_(my_my_strlcat)(char * dst, const char * src, Size_t size);
  7163. +static
  7164. +#else
  7165. +extern Size_t DPPP_(my_my_strlcat)(char * dst, const char * src, Size_t size);
  7166. +#endif
  7167. +
  7168. +#define my_strlcat DPPP_(my_my_strlcat)
  7169. +#define Perl_my_strlcat DPPP_(my_my_strlcat)
  7170. +
  7171. +#if defined(NEED_my_strlcat) || defined(NEED_my_strlcat_GLOBAL)
  7172. +
  7173. +Size_t
  7174. +DPPP_(my_my_strlcat)(char *dst, const char *src, Size_t size)
  7175. +{
  7176. + Size_t used, length, copy;
  7177. +
  7178. + used = strlen(dst);
  7179. + length = strlen(src);
  7180. + if (size > 0 && used < size - 1) {
  7181. + copy = (length >= size - used) ? size - used - 1 : length;
  7182. + memcpy(dst + used, src, copy);
  7183. + dst[used + copy] = '\0';
  7184. + }
  7185. + return used + length;
  7186. +}
  7187. +#endif
  7188. +#endif
  7189. +
  7190. +#if !defined(my_strlcpy)
  7191. +#if defined(NEED_my_strlcpy)
  7192. +static Size_t DPPP_(my_my_strlcpy)(char * dst, const char * src, Size_t size);
  7193. +static
  7194. +#else
  7195. +extern Size_t DPPP_(my_my_strlcpy)(char * dst, const char * src, Size_t size);
  7196. +#endif
  7197. +
  7198. +#define my_strlcpy DPPP_(my_my_strlcpy)
  7199. +#define Perl_my_strlcpy DPPP_(my_my_strlcpy)
  7200. +
  7201. +#if defined(NEED_my_strlcpy) || defined(NEED_my_strlcpy_GLOBAL)
  7202. +
  7203. +Size_t
  7204. +DPPP_(my_my_strlcpy)(char *dst, const char *src, Size_t size)
  7205. +{
  7206. + Size_t length, copy;
  7207. +
  7208. + length = strlen(src);
  7209. + if (size > 0) {
  7210. + copy = (length >= size) ? size - 1 : length;
  7211. + memcpy(dst, src, copy);
  7212. + dst[copy] = '\0';
  7213. + }
  7214. + return length;
  7215. +}
  7216. +
  7217. +#endif
  7218. +#endif
  7219. +#ifndef PERL_PV_ESCAPE_QUOTE
  7220. +# define PERL_PV_ESCAPE_QUOTE 0x0001
  7221. +#endif
  7222. +
  7223. +#ifndef PERL_PV_PRETTY_QUOTE
  7224. +# define PERL_PV_PRETTY_QUOTE PERL_PV_ESCAPE_QUOTE
  7225. +#endif
  7226. +
  7227. +#ifndef PERL_PV_PRETTY_ELLIPSES
  7228. +# define PERL_PV_PRETTY_ELLIPSES 0x0002
  7229. +#endif
  7230. +
  7231. +#ifndef PERL_PV_PRETTY_LTGT
  7232. +# define PERL_PV_PRETTY_LTGT 0x0004
  7233. +#endif
  7234. +
  7235. +#ifndef PERL_PV_ESCAPE_FIRSTCHAR
  7236. +# define PERL_PV_ESCAPE_FIRSTCHAR 0x0008
  7237. +#endif
  7238. +
  7239. +#ifndef PERL_PV_ESCAPE_UNI
  7240. +# define PERL_PV_ESCAPE_UNI 0x0100
  7241. +#endif
  7242. +
  7243. +#ifndef PERL_PV_ESCAPE_UNI_DETECT
  7244. +# define PERL_PV_ESCAPE_UNI_DETECT 0x0200
  7245. +#endif
  7246. +
  7247. +#ifndef PERL_PV_ESCAPE_ALL
  7248. +# define PERL_PV_ESCAPE_ALL 0x1000
  7249. +#endif
  7250. +
  7251. +#ifndef PERL_PV_ESCAPE_NOBACKSLASH
  7252. +# define PERL_PV_ESCAPE_NOBACKSLASH 0x2000
  7253. +#endif
  7254. +
  7255. +#ifndef PERL_PV_ESCAPE_NOCLEAR
  7256. +# define PERL_PV_ESCAPE_NOCLEAR 0x4000
  7257. +#endif
  7258. +
  7259. +#ifndef PERL_PV_ESCAPE_RE
  7260. +# define PERL_PV_ESCAPE_RE 0x8000
  7261. +#endif
  7262. +
  7263. +#ifndef PERL_PV_PRETTY_NOCLEAR
  7264. +# define PERL_PV_PRETTY_NOCLEAR PERL_PV_ESCAPE_NOCLEAR
  7265. +#endif
  7266. +#ifndef PERL_PV_PRETTY_DUMP
  7267. +# define PERL_PV_PRETTY_DUMP PERL_PV_PRETTY_ELLIPSES|PERL_PV_PRETTY_QUOTE
  7268. +#endif
  7269. +
  7270. +#ifndef PERL_PV_PRETTY_REGPROP
  7271. +# define PERL_PV_PRETTY_REGPROP PERL_PV_PRETTY_ELLIPSES|PERL_PV_PRETTY_LTGT|PERL_PV_ESCAPE_RE
  7272. +#endif
  7273. +
  7274. +/* Hint: pv_escape
  7275. + * Note that unicode functionality is only backported to
  7276. + * those perl versions that support it. For older perl
  7277. + * versions, the implementation will fall back to bytes.
  7278. + */
  7279. +
  7280. +#ifndef pv_escape
  7281. +#if defined(NEED_pv_escape)
  7282. +static char * DPPP_(my_pv_escape)(pTHX_ SV * dsv, char const * const str, const STRLEN count, const STRLEN max, STRLEN * const escaped, const U32 flags);
  7283. +static
  7284. +#else
  7285. +extern char * DPPP_(my_pv_escape)(pTHX_ SV * dsv, char const * const str, const STRLEN count, const STRLEN max, STRLEN * const escaped, const U32 flags);
  7286. +#endif
  7287. +
  7288. +#ifdef pv_escape
  7289. +# undef pv_escape
  7290. +#endif
  7291. +#define pv_escape(a,b,c,d,e,f) DPPP_(my_pv_escape)(aTHX_ a,b,c,d,e,f)
  7292. +#define Perl_pv_escape DPPP_(my_pv_escape)
  7293. +
  7294. +#if defined(NEED_pv_escape) || defined(NEED_pv_escape_GLOBAL)
  7295. +
  7296. +char *
  7297. +DPPP_(my_pv_escape)(pTHX_ SV *dsv, char const * const str,
  7298. + const STRLEN count, const STRLEN max,
  7299. + STRLEN * const escaped, const U32 flags)
  7300. +{
  7301. + const char esc = flags & PERL_PV_ESCAPE_RE ? '%' : '\\';
  7302. + const char dq = flags & PERL_PV_ESCAPE_QUOTE ? '"' : esc;
  7303. + char octbuf[32] = "%123456789ABCDF";
  7304. + STRLEN wrote = 0;
  7305. + STRLEN chsize = 0;
  7306. + STRLEN readsize = 1;
  7307. +#if defined(is_utf8_string) && defined(utf8_to_uvchr)
  7308. + bool isuni = flags & PERL_PV_ESCAPE_UNI ? 1 : 0;
  7309. +#endif
  7310. + const char *pv = str;
  7311. + const char * const end = pv + count;
  7312. + octbuf[0] = esc;
  7313. +
  7314. + if (!(flags & PERL_PV_ESCAPE_NOCLEAR))
  7315. + sv_setpvs(dsv, "");
  7316. +
  7317. +#if defined(is_utf8_string) && defined(utf8_to_uvchr)
  7318. + if ((flags & PERL_PV_ESCAPE_UNI_DETECT) && is_utf8_string((U8*)pv, count))
  7319. + isuni = 1;
  7320. +#endif
  7321. +
  7322. + for (; pv < end && (!max || wrote < max) ; pv += readsize) {
  7323. + const UV u =
  7324. +#if defined(is_utf8_string) && defined(utf8_to_uvchr)
  7325. + isuni ? utf8_to_uvchr((U8*)pv, &readsize) :
  7326. +#endif
  7327. + (U8)*pv;
  7328. + const U8 c = (U8)u & 0xFF;
  7329. +
  7330. + if (u > 255 || (flags & PERL_PV_ESCAPE_ALL)) {
  7331. + if (flags & PERL_PV_ESCAPE_FIRSTCHAR)
  7332. + chsize = my_snprintf(octbuf, sizeof octbuf,
  7333. + "%"UVxf, u);
  7334. + else
  7335. + chsize = my_snprintf(octbuf, sizeof octbuf,
  7336. + "%cx{%"UVxf"}", esc, u);
  7337. + } else if (flags & PERL_PV_ESCAPE_NOBACKSLASH) {
  7338. + chsize = 1;
  7339. + } else {
  7340. + if (c == dq || c == esc || !isPRINT(c)) {
  7341. + chsize = 2;
  7342. + switch (c) {
  7343. + case '\\' : /* fallthrough */
  7344. + case '%' : if (c == esc)
  7345. + octbuf[1] = esc;
  7346. + else
  7347. + chsize = 1;
  7348. + break;
  7349. + case '\v' : octbuf[1] = 'v'; break;
  7350. + case '\t' : octbuf[1] = 't'; break;
  7351. + case '\r' : octbuf[1] = 'r'; break;
  7352. + case '\n' : octbuf[1] = 'n'; break;
  7353. + case '\f' : octbuf[1] = 'f'; break;
  7354. + case '"' : if (dq == '"')
  7355. + octbuf[1] = '"';
  7356. + else
  7357. + chsize = 1;
  7358. + break;
  7359. + default: chsize = my_snprintf(octbuf, sizeof octbuf,
  7360. + pv < end && isDIGIT((U8)*(pv+readsize))
  7361. + ? "%c%03o" : "%c%o", esc, c);
  7362. + }
  7363. + } else {
  7364. + chsize = 1;
  7365. + }
  7366. + }
  7367. + if (max && wrote + chsize > max) {
  7368. + break;
  7369. + } else if (chsize > 1) {
  7370. + sv_catpvn(dsv, octbuf, chsize);
  7371. + wrote += chsize;
  7372. + } else {
  7373. + char tmp[2];
  7374. + my_snprintf(tmp, sizeof tmp, "%c", c);
  7375. + sv_catpvn(dsv, tmp, 1);
  7376. + wrote++;
  7377. + }
  7378. + if (flags & PERL_PV_ESCAPE_FIRSTCHAR)
  7379. + break;
  7380. + }
  7381. + if (escaped != NULL)
  7382. + *escaped= pv - str;
  7383. + return SvPVX(dsv);
  7384. +}
  7385. +
  7386. +#endif
  7387. +#endif
  7388. +
  7389. +#ifndef pv_pretty
  7390. +#if defined(NEED_pv_pretty)
  7391. +static char * DPPP_(my_pv_pretty)(pTHX_ SV * dsv, char const * const str, const STRLEN count, const STRLEN max, char const * const start_color, char const * const end_color, const U32 flags);
  7392. +static
  7393. +#else
  7394. +extern char * DPPP_(my_pv_pretty)(pTHX_ SV * dsv, char const * const str, const STRLEN count, const STRLEN max, char const * const start_color, char const * const end_color, const U32 flags);
  7395. +#endif
  7396. +
  7397. +#ifdef pv_pretty
  7398. +# undef pv_pretty
  7399. +#endif
  7400. +#define pv_pretty(a,b,c,d,e,f,g) DPPP_(my_pv_pretty)(aTHX_ a,b,c,d,e,f,g)
  7401. +#define Perl_pv_pretty DPPP_(my_pv_pretty)
  7402. +
  7403. +#if defined(NEED_pv_pretty) || defined(NEED_pv_pretty_GLOBAL)
  7404. +
  7405. +char *
  7406. +DPPP_(my_pv_pretty)(pTHX_ SV *dsv, char const * const str, const STRLEN count,
  7407. + const STRLEN max, char const * const start_color, char const * const end_color,
  7408. + const U32 flags)
  7409. +{
  7410. + const U8 dq = (flags & PERL_PV_PRETTY_QUOTE) ? '"' : '%';
  7411. + STRLEN escaped;
  7412. +
  7413. + if (!(flags & PERL_PV_PRETTY_NOCLEAR))
  7414. + sv_setpvs(dsv, "");
  7415. +
  7416. + if (dq == '"')
  7417. + sv_catpvs(dsv, "\"");
  7418. + else if (flags & PERL_PV_PRETTY_LTGT)
  7419. + sv_catpvs(dsv, "<");
  7420. +
  7421. + if (start_color != NULL)
  7422. + sv_catpv(dsv, D_PPP_CONSTPV_ARG(start_color));
  7423. +
  7424. + pv_escape(dsv, str, count, max, &escaped, flags | PERL_PV_ESCAPE_NOCLEAR);
  7425. +
  7426. + if (end_color != NULL)
  7427. + sv_catpv(dsv, D_PPP_CONSTPV_ARG(end_color));
  7428. +
  7429. + if (dq == '"')
  7430. + sv_catpvs(dsv, "\"");
  7431. + else if (flags & PERL_PV_PRETTY_LTGT)
  7432. + sv_catpvs(dsv, ">");
  7433. +
  7434. + if ((flags & PERL_PV_PRETTY_ELLIPSES) && escaped < count)
  7435. + sv_catpvs(dsv, "...");
  7436. +
  7437. + return SvPVX(dsv);
  7438. +}
  7439. +
  7440. +#endif
  7441. +#endif
  7442. +
  7443. +#ifndef pv_display
  7444. +#if defined(NEED_pv_display)
  7445. +static char * DPPP_(my_pv_display)(pTHX_ SV * dsv, const char * pv, STRLEN cur, STRLEN len, STRLEN pvlim);
  7446. +static
  7447. +#else
  7448. +extern char * DPPP_(my_pv_display)(pTHX_ SV * dsv, const char * pv, STRLEN cur, STRLEN len, STRLEN pvlim);
  7449. +#endif
  7450. +
  7451. +#ifdef pv_display
  7452. +# undef pv_display
  7453. +#endif
  7454. +#define pv_display(a,b,c,d,e) DPPP_(my_pv_display)(aTHX_ a,b,c,d,e)
  7455. +#define Perl_pv_display DPPP_(my_pv_display)
  7456. +
  7457. +#if defined(NEED_pv_display) || defined(NEED_pv_display_GLOBAL)
  7458. +
  7459. +char *
  7460. +DPPP_(my_pv_display)(pTHX_ SV *dsv, const char *pv, STRLEN cur, STRLEN len, STRLEN pvlim)
  7461. +{
  7462. + pv_pretty(dsv, pv, cur, pvlim, NULL, NULL, PERL_PV_PRETTY_DUMP);
  7463. + if (len > cur && pv[cur] == '\0')
  7464. + sv_catpvs(dsv, "\\0");
  7465. + return SvPVX(dsv);
  7466. +}
  7467. +
  7468. +#endif
  7469. +#endif
  7470. +
  7471. +#endif /* _P_P_PORTABILITY_H_ */
  7472. +
  7473. +/* End of File ppport.h */