summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* expand code comment in perly.yDavid Mitchell2017-11-164-12/+10
| | | | | | ASSIGNOP includes mutators like += as well as basic assignment NPD
* deparse ::CORE::foo barewords carefullyZefram2017-11-162-0/+4
| | | | | | | A bareword such as "::CORE::foo", where it refers to a GV, is liable to be confused with the "CORE::foo" syntax, which can't refer to a GV but is a way of supplying a keyword, and is illegal if the keyword doesn't exist. Make sure to deparse it with the "::" prefix. Fixes [perl #113714].
* rip out CPAN-release cruft from B::DeparseZefram2017-11-161-135/+11
| | | | | B::Deparse is distributed only with the core. It has no need to be portable between Perl versions or to have its own change log.
* additional tests for registered warning categoriesZefram2017-11-161-4/+19
|
* IO::Handle - fix precedence issueNicolas R2017-11-151-9/+9
| | | | | | | | This commits fixes remarks raised during the 2017 p5h in Amsterdam. - fix precedence issue with '=~' - stop using indirect new calls for SelectSaver.
* spellingKaren Etheridge2017-11-151-2/+2
|
* tabs to spaces in RMGKaren Etheridge2017-11-151-3/+3
|
* fix handling of registered warning categoriesZefram2017-11-158-132/+165
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There were some problems arising from some warning bitsets being shorter than others, which happens when registration of a new warning category makes new bitsets longer. Most obviously, if a scope used "use warnings 'all'" to turn on all warnings and then turned off some specific warnings, then that scope wouldn't get warnings for subsequently-registered warning categories, because its bitset doesn't extend to the bit controlling the new category. (If just "use warnings 'all'" was used, without any customisation, then a special hack made that work for new categories.) It was also possible for a longer bitset to get truncated by a warnings pragma, because the bitset editing code assumed that all bitsets are the same length. To fix this, first the warning bits for the "all" category have to change meaning. Unlike all other warning categories, the bits for "all" used to be set only when there were no warning categories disabled; disabling any would also clear the "all" bits. That was supporting the special hack mentioned above that the all-warnings bitset work for new categories. This exception is now removed, so the meaning of the "all" bits is now the more obvious meaning, of indicating the default treatment that the scope wants for warnings not falling into any category known to the bitset. In warnings::warnif() et al, if the caller's bitset is found to be too short to have a bit for the relevant category, then the setting for the "all" category is used instead. Because the length of a bitset is an integral number of bytes, but only two bits are used per category, the length of a bitset doesn't precisely indicate which categories had been registered by the time it was constructed. So the standard bitsets for the "all" category are now always filled to their byte length, with bits set preemptively for categories not yet registered that fall within the current bitset length. When a warnings pragma operates on a bitset, it first expands it to the preferred length, by duplicating the "all" bits for the categories covered by the new length. It is careful to maintain the length when combining the bitset with the standard bitsets for categories. When a bitset is read from ${^WARNING_BITS} or from caller(), the standard pWARN_ALL setting is no longer expanded by the core to $warnings::Bits{all}, because the core's short WARN_ALLstring will now be expanded correctly just like any other bitset. Fixes [perl #108778].
* Provide option to build with -D__USE_MINGW_ANSI_STDIOSteve Hay2017-11-152-4/+23
| | | | | | | | | | | | | | This commit adapts and extends a patch from sisyphus1@optusnet.com.au on perl #130447. Note for the future: One of the MinGW/gcc developers has said that explicitly defining __USE_MINGW_ANSI_STDIO in this way is not guaranteed to work in the future, so we may have to pursue other options instead one day: https://rt.perl.org/Ticket/Display.html?id=130447#txn-1461711 However, we already do this for "nvtype=long double" builds and it's working fine so far, so it seems acceptable to allow the same thing for "nvtype=double" builds for now.
* DynaLoader simplify parsing option ruleNicolas R2017-11-151-6/+4
| | | | | | | | | | After review, comments & dumb benchmark. Simply using a substitute for these two '-L' and '-l' options parsing makes the code easier to maintain. The benchmark difference is pretty close, for matching, non matching (short or long) strings.
* Remove use vars from B::DeparseTodd Rinaldo2017-11-153-3/+5
| | | | | RT 132429: This causes a slight change to the output value of ${^WARNING_BITS} due to warnings::register not polluting introspection for B::Deparse.
* perldelta for commit 43b354f1e1Steve Hay2017-11-151-2/+3
|
* lib/perl5db.pl: don't dump argless argsDavid Mitchell2017-11-151-8/+4
| | | | | | | | | | | | | | | | | | | | dump_trace() prints a stack backtrace - including caller args - by using caller() and @DB::args. However, if a sub is called using the '&foo;' argless mechanism, caller() doesn't populate @DB::args, so it continues to hold whatever it was set to previously. This might include SVs which have since been freed or re-allocated. So only display args for a particular caller depth if that sub was called with args. This was causing smoke failures in lib/perl5db.t when TERM was unset. It only started failing recently, due I guess to subtle changes in what SVs were left hanging about in @DB::args from a previous use of caller(). See http://nntp.perl.org/group/perl.perl5.porters/247032 Subject: Smoke FAIL's for lib/perl5db.t
* lib/perl5db.t: remove debugging codeDavid Mitchell2017-11-151-1/+0
| | | | A spurious printf was inadvertently added by me with e05a85b2.
* Improve cl version detectionSteve Hay2017-11-151-12/+7
| | | | | | | | | | | | | | | Drop the use of the word "Version" so it works on non-English systems. Instead, simply look for a number of the form X.Y (or X.Y.Z etc) with word boundaries around it. Thus, we can find numbers like 12.00.8804 or 19.00.24213.1, but not accidentally pick up things like x86 or 1984-1998. Also, drop the "--version" argument since it doesn't really exist and causes warnings/errors to be output. A bare "cl" command suffices to get a usage message including the version number to be output. Finally, the Windows version detection can be similarly improved. This fixes perl #132421.
* perldelta for stat(CLOSED) fixZefram2017-11-151-0/+5
|
* set $! when statting a closed filehandleZefram2017-11-154-10/+80
| | | | | | | When a stat fails because it's on a closed or otherwise invalid filehandle, $! was often not being set, depending on the operation and the nature of the invalidity. Consistently set it to EBADF. Fixes [perl #108288].
* POSIX.pod: Add cautions about locale useKarl Williamson2017-11-141-1/+7
|
* locale.c: Use mnemonicKarl Williamson2017-11-141-1/+1
| | | | Replace this number by an already existing mnemonic
* perldelta for the prev. commitFather Chrysostomos2017-11-141-0/+6
|
* [perl #132442] Fix stack with do {my sub l; 1}Father Chrysostomos2017-11-142-1/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A block in perl usually compiles to a leave op with an enter inside it, followed by the statements: leave enter nextstate ... expr ... nextstate ... expr ... If a block contains only one statement, and that statement is suffic- iently innocuous, then the enter/leave pair to create the scope at run time get skipped, and instead we have a simple scope op which is not even executed: scope ex-nextstate ... expr ... The nextstate in this case also gets nulled. In the case of do { my sub l; 1 } we were getting a variation of the latter, that looked like this: scope introcv clonecv nextstate ... expr ... The problem here is that nextstate resets the stack, even though a new scope has not been pushed, so we end up with all existing stack items from the *outer* scope getting clobbered. One can have fun with this and erase everything pushed on to the stack so far in a given statement: $ ./perl -le 'print join "-", 1..10, do {my sub l; ","}, 11..20' 11,12,13,14,15,16,17,18,19,20 Here I replaced the first argument to join() from within the do{} block, after having cleared the stack. Why was the op tree was getting muddled up like this? The ‘my sub’ declaration does not immediately add any ops to the op tree; those ops get added when the current scope finishing compiling, since those ops must be inserted at the beginning of the block. I have not fully looked into the order that things happen, and why the nextstate op does not get nulled; but it did not matter, because of the simple fix: Treat lexical sub declarations as ‘not innocuous’ by setting the HINT_BLOCK_SCOPE flag when a lexical sub is declared. Thus, we end up with an enter/leave pair, which creates a proper scope.
* Update experimental.pm from 0.016 to 0.017Sawyer X2017-11-142-13/+70
|
* perldelta for 6b93e4bc22a7c06508c3d2ed4590fe8bc2cb4989James E Keenan2017-11-141-0/+6
|
* Compress-Raw-Zlib: sync with CPAN version 2.075Paul Marquess2017-11-1421-792/+1275
| | | | | | | | | | https://rt.cpan.org/Ticket/Display.html?id=123245 reports a security vulnerability in versions zlib 1.2.8 thru 1.2.10 of the zlib library. Zlib is bundled with Compress-Raw-Zlib, so any vulnerability reappears once Compress-Raw-Zlib is shipped with Perl 5. The vulnerability is present in production releases up to and including perl-5.26.1. To address this vulnerability, this commit upgrades us to the latest CPAN version.
* OP_MULTICONCAT: fix AIXDavid Mitchell2017-11-141-1/+1
| | | | | | The OP_MULTICONCAT work broke AIX builds because it turns out that PerlMemShared_malloc() isn't safe (in the sense of safemalloc()); i.e. on AIX, PerlMemShared_malloc(0) returns NULL.
* Upgrade libnet from version 3.10 to 3.11Steve Hay2017-11-1417-103/+103
| | | | This includes https://github.com/steve-m-hay/perl-libnet/pull/32
* Fix Windows build failure introduced by 7d00a3405cSteve Hay2017-11-141-1/+4
|
* Handle empty list in Perl_vms_do_aexec.Craig A. Berry2017-11-141-0/+1
| | | | | Since 2fcab33080e this is now expected and tested for, so do what other platforms do.
* mv "Truth and Falsehood" from perlsyn to perldataZefram2017-11-143-12/+13
| | | | | This one-paragraph section didn't belong in perlsyn. perldata already had a paragraph on the topic; merge them. [perl #115650]
* fix newPVOP() doc re freeing of pvZefram2017-11-141-3/+4
| | | | [perl #127697]
* perldelta: typoAaron Crane2017-11-141-1/+1
| | | | Ilmari++
* perldelta: C89 requirementAaron Crane2017-11-141-0/+8
|
* fix naming of some test temp filesZefram2017-11-147-69/+70
| | | | | The files should be named t/tmp*, to fall under .gitignore and be ignored by podcheck.
* fix ext/B/t/optree_specials.tDavid Mitchell2017-11-141-12/+18
| | | | | | | | | recent changes to expected output didn't account for the way nextstate ops change their hints display when run under LC_ALL=en_US.UTF-8 PERL_UNICODE="" One day we'll make this automatic.
* stop unused-var warnings in ExtUtils-ParseXS testsZefram2017-11-143-0/+5
| | | | | These are warnings resulting from unusual features of the specific XS code in the test suite, not from XS compilation in general.
* avoid unused-var warnings in compiled XSZefram2017-11-1411-11/+17
| | | | | | | Code generated by ExtUtils-ParseXS for certain kinds of XS sub was creating an "items" variable and never using it, resulting in distracting warnings from the C compiler. Add "PERL_UNUSED_VAR(items)" where appropriate.
* rip out Perl version portability from BZefram2017-11-1410-437/+109
| | | | | B is distributed only with the core, not dual-life, so has no need to be portable between Perl versions.
* in B::Concise, show RV target betterZefram2017-11-143-8/+59
| | | | | Especially show the identity of CVs where possible. This is important now that gv ops often point at a coderef rather than a glob. Fixes [perl
* Introduce macros to simplify @INC settingNicolas R2017-11-133-124/+205
| | | | | | | | | | | | Distro trends to customize @INC, and to maintain patches to change the order of @INC or add custom entries. The goal of this patch is to abstract calls to 'S_incpush_use_sep' and simplify reordering @INC. This commit makes the code from perl.c more comfortable to read by introducing several 'INCPUSH_*' macros for every 'S_incpush_use_sep' call so we can easily reorder them.
* Storable: remove Config dependencyNicolas R2017-11-136-11/+61
| | | | | | | | | | | | | | | | | | RT #132406 Avoid loading Config/Config_heavy from Storable. Make Storable.pm a template file and check if the system can use flock at compile time. __Storable__.pm is the template file to edit, whereas Storable.pm.PL is the script generating Storable.pm from __Storable__.pm. Using a separate file for the template make it easier to edit. Also note that Storable.pm is now ignored by git.
* Time::HiRes disable a flapping test for CINicolas R2017-11-132-3/+16
| | | | | | | | | When running this test under heavy load we cannot assume the delta between two system calls... even when using a (nano)sleep Most Continuous Integration system will fail on this test at one point or the other.
* Make perlbug.t forgiving about newlines.Craig A. Berry2017-11-131-1/+1
| | | | | | On VMS, pipes often introduce extra newlines, so the test infrastructure deduplicates them, which then makes it impossible to check for more than one. So just check for one or more.
* travis.yaml: fixes for osxNicolas R2017-11-131-2/+2
| | | | | run brew update before installing ccache use TRAVIS_OS_NAME macro to check os
* Adjust porting/authors.t for travisciNicolas R2017-11-131-1/+11
| | | | | | | | | | | Add plan to porting/authors.t skip_plan was used but no plan or tap output was defined. When the test is run by TravisCI, use a shorten revision range. We do not want to have a pull request impacted by the previous state of blead, and we do not want to check the merge commit from travis which is using the github author primary email address.
* Remove win32 logic from t/porting/authors.tNicolas R2017-11-131-6/+9
| | | | | Remove special logic for windows by using 'qx'. Allow test to be run from main root directory.
* Switch some core modules to XSLoaderNicolas R2017-11-136-22/+20
| | | | | | | | RT 132080: Remove perl 5.006 compatibilities with DynaLoader and use XSLoader directly. The traditional boiler plate to use XSLoader for Perl > 5.006 or DynaLoader, does not make sense for core modules in perl 5.28+.
* Track Unicode-Normalize Changes file so it can be updated as it is changed ↵Todd Rinaldo2017-11-132-0/+256
| | | | in Perl
* Tweak travis.yml: ccache & notificationsNicolas R2017-11-131-1/+32
| | | | | | - builds are now using ccache - use multiline syntax for main script - irc notifications are now enabled and sent to #p5p-qa channel
* Makefile.SH: factorize install.html targetNicolas R2017-11-131-27/+16
| | | | | | Avoid duplicate definition of install.man and install.html targets. We could then use in a later commit a Configure option to disable doc installation on demand.
* Update Unicode-Collate to CPAN version 1.23Chris 'BinGOs' Williams2017-11-13109-153/+305
| | | | | | | | | | | | | | | [DELTA] 1.23 Mon Nov 13 19:10:28 2017 - Now UCA_Version 36 (for Unicode 10.0.0) is supported. * But the default UCA_Version is still 34. - added nushu.t in t. 1.22 Sat Nov 11 10:53:35 2017 - internal: someone suggests using 'exists' for checking the truth of $collator->{mapping}{$variable} and $collator->{maxlength}{$variable}, where $variable may stand for codepoints whose mapping is not defined; though such a problem was not reproduced on my environment.