summaryrefslogtreecommitdiff
path: root/vutil.c
Commit message (Collapse)AuthorAgeFilesLines
* vutil.c: use new SvPVCLEAR and constant string friendly macrosYves Orton2016-10-191-4/+4
|
* Update version to 0.9916John Peacock2016-03-191-10/+0
|
* Various fixups for version.pm 0.9914Leon Timmermans2016-03-171-1/+2
|
* Import version.pm 0.9914 from CPANJohn Peacock2016-03-171-107/+93
|
* PATCH: [perl #121930] Bleadperl breaks MDOOTSON/WxKarl Williamson2014-08-111-0/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The root cause of this issue is that XS code or the libraries it calls is changing the locale behind Perl's back so that the decimal point character is not a dot. Version number parsing relies on it being a dot. This patch fixes the problem by retrieving the current locale just before version number parsing, and updating Perl's records if the locale has changed away from what is expected. Given accurate records, the pre-existing call to the STORE_NUMERIC_LOCAL_SET_STANDARD macro will do what it's supposed to do, and change the locale so that the dot is the radix character for the version number parsing. After the parsing is done, the pre-existing call to the RESTORE_NUMERIC_LOCAL macro will restore properly, but see below This patch should be suitable for both 5.20.1 and 5.21 (though the SHA-1 value in the porting/customize.dat will have to be adjusted because the files aren't otherwise identical). But there is a fundamental difference between the releases. In 5.20.X, Perl does not attempt to keep the radix character a dot at almost all times (though it initializes things so it is a dot, overriding any environmental settings to the contrary). This leads to known non-regression bugs in 5.20 because very little XS code can cope with a non-dot. To fix this, Perl has changed the macros in 5.21 so that the result after the RESTORE_NUMERIC_LOCAL is that the current locale will have a dot. This will fix those long-standing bugs where XS code expecting a dot fails should it be mashed up with modules that change it to something else. But this will break the relatively few modules that want it the other way. So it has been done early in 5.21 to give things a chance to settle down. The extra {} braces around the code that calls the macros is because STORE_NUMERIC_LOCAL_SET_STANDARD declares a variable, and so must be within the declarations area of a block for C89 compilers. (I myself would not write a macro that does this without indicating so in its name.)
* perlapi: Refactor placements, headings of some functionsKarl Williamson2014-06-051-0/+2
| | | | | | | | | | | | | | It is not very user friendly to list functions as "Functions found in file FOO". Better is to group them by purpose, as many were already. I went through and placed the ones that weren't already so grouped into groups. Patches welcome if you have a better classification. I changed the headings of some so that the important disctinction was the first word so that they are placed in the file more appropriately. And a couple of ones that I had created myself, I came up with a name that I think is better than the original
* Allow dynamic lock of LC_NUMERICKarl Williamson2014-06-051-0/+2
| | | | | | | | | | | When processing version strings, the radix character must be a dot even if we otherwise would be using some other character. vutil.c upg_version() changes to the dot, but calls sv_catpvf() which may try to change the character to something else. This commit introduces a way to lock the character to a dot around the call to sv_catpvf() vutil.c is cpan-upstream, but already blead and cpan have diverged, so this just updates the SHA of the new version
* vutil.c, vxs.inc: Avoid warnings from -Wmissing-prototypes -Wundef ↵Brian Fraser2014-02-041-9/+15
| | | | | | | | | | | | -Wunused-label -Wmissing-prototypes was complaining about declaring XS() functions without previously declaring a prototype. -Wundef didn't like using #if foo instead of #ifdef foo -Wunused-label warned because VER_{IV,NM,PV} were defined on all versions of perl, but only used on < 5.17.2
* And now the rest of the sync to 0.9908John Peacock2014-02-041-18/+35
|
* Sync bleadperl to version.pm 0.9908John Peacock2014-02-031-0/+5
| | | | | | | | | | | | | | | | | | | | Attached is a patch to bring blead up to date with the latest CPAN release of version.pm 0.9908. All tests pass (except the expected porting/customized.t). I'm hopeful that this will be the last update for a while. Thanks to Daniel Dragan for his insistent prodding to improve the code. ;-) Thanks John >From c501530aa386a3ccbdb35bcccbccd35d70315651 Mon Sep 17 00:00:00 2001 From: John Peacock <jpeacock@cpan.org> Date: Sun, 2 Feb 2014 11:57:44 -0500 Subject: [PATCH] Update bleadperl to CPAN 0.9908 release Signed-off-by: Chris 'BinGOs' Williams <chris@bingosnet.co.uk>
* Explicit ENTER/LEAVE block for upg_versionJohn Peacock2014-01-181-0/+2
|
* Lots of C optimizations for both speed/correctnessJohn Peacock2014-01-181-38/+62
| | | | | | | | | | | Clean up a lot of the less efficient uses of various Perl macros and functions, mostly from bulk88@hotmail.com. Also deal with the fact that older Perl's were not handling locale setting in a consistent manner. This means going back to the less efficient but always correct method of ALWAYS copying the old locale and switch to C and then restoring, for all Perl releases prior to 5.19.0. Discontinue support for Perl's prior to v5.6.2.
* vutil.c: Use existing macros instead of reinventing themKarl Williamson2014-01-041-13/+2
| | | | | | If there had been documentation referring to these macros, I would have known they existed instead of reinventing them (not as well as the originals).
* Do not crash if passed garbage like array.John Peacock2014-01-041-3/+9
| | | | | Somehow we lost the test that caught getting passed an arrayref instead of a simple scalar. Also integrate fix from perl rt#120872.
* Grab latest changes from CPAN 0.9905John Peacock2014-01-041-1/+5
|
* Integrate CPAN version.pm release into coreJohn Peacock2014-01-041-1/+10
|
* vutil.c: Add preproc code specific to CPANFather Chrysostomos2014-01-041-12/+60
| | | | | | | The purpose is to bring the files into synch so that later version.pm upgrades involve dropping files into place. This requires changing vutil.h a bit to work in the core.
* Extract version routines into two new filesFather Chrysostomos2014-01-041-0/+942
This is to make synchronisation between the CPAN distribution and the perl core easier. The files have different extensions to match what the CPAN distribu- tion will have. vutil.c is a separate compilation unit that the CPAN dist already has. vxs.inc will be included by vxs.xs (vxs.c is obvi- ously alreday taken, being generated from vxs.xs). In the perl core util.c includes vutil.c and universal.c includes vxs.inc.