summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* Add new release to perlhistv5.37.7Richard Leach2022-12-201-0/+1
|
* Update t/porting/customized.dat for 5.37.7Richard Leach2022-12-201-8/+0
|
* Update perldelta.pod for 5.37.7Richard Leach2022-12-201-309/+77
|
* Update Module::CoreList for 5.37.7Richard Leach2022-12-201-0/+39
|
* Address GH #20571Karl Williamson2022-12-204-14/+61
| | | | | | | | | | | | The blamed commit, 04de022, exposed a bug in the module itself. I will submit a PR to fix it. But this ticket did tell me that there was a problem with that commit. It returned a C language value, CHAR_MAX, which doesn't really have a corresponding concept in Perl. Instead we use -1 to indicate that a positive-valued variable is in some abnormal state. This commit changes to do that, and documents the changes, which should have been done in 04de022.
* Fix broken API: sync_locale()Karl Williamson2022-12-205-48/+63
| | | | | | | | | | | | | | This fixes GH #20565. Lack of tests allowed sync_locale() to get broken until CPAN testing showed it so. Basically, I blew it in 9f5a615be674d7663d3b4719849baa1ba3027f5b. Most egregiously, I forgot to turn back on when a sync_locale() is executed, the toggling for locales whose radix character isn't a dot. And this needs a way to tell the other code that it needs to recompute things at this time, since our records don't reflect what happened before the sync.
* Add testing global locale switching; Todo #20565Karl Williamson2022-12-202-0/+60
| | | | | | API switch_to_global_locale() and sync_locale() weren't tested because I hadn't figured out a way to do so, but @dk showed me the way in his reproducing case for GH #20565.
* API-test:locale.t: Look for a comma radix localeKarl Williamson2022-12-201-5/+7
| | | | | | | | | | | Prior to this commit there was code (whose results were ignored) looking for a locale with a non-dot radix. This can result in a UTF-8 radix, which may not display properly without the terminal and file handle being in sync. Almost all non-dot locales use a comma, which is represented the same in UTF-8 as not, so doesn't suffer from the display problem. So look specifically for a comma. The result is still unused, but the next commit will use it.
* locale.c: ClarificationsKarl Williamson2022-12-201-9/+10
| | | | | This commit adds/improves some comments, changes a variable name, and adds some parentheses, and moves a declaration (since we now use C99).
* Define OP_HELEMEXISTSOR, a handy LOGOP shortcut for HELEM existence testsPaul "LeoNerd" Evans2022-12-1911-2/+134
| | | | | | | | | | | | | | | | | | This op is constructed using an OP_HELEM as the op_first and any scalar expression as the op_other. It is roughly equivalent to the following perl code: exists $hv{$key} ? $hv{$key} : OTHER except that the HV and the KEY expression are evaluated only once, and only one hv_* function is invoked to both test and obtain the value. It is therefore smaller and more efficient. Likewise, adding the OPpHELEMEXISTSOR_DELETE flag turns it into the equivalent of exists $hv{$key} ? delete $hv{$key} : OTHER
* locale.c: No locales imples no UTF-8 onesKarl Williamson2022-12-191-1/+2
| | | | | | If Perl is compiled to not pay attention at all to locales, everything effectively becomes the C locale, which isn't a UTF-8 one. So we know that at compile time.
* perldelta for 3 upgraded CPAN modulesJames E Keenan2022-12-191-0/+12
|
* Update experimental to CPAN version 0.030Leon Timmermans2022-12-193-5/+12
| | | | Adapt to future deprecation of smartmatch
* harness: When run in ASAP mode, intermix comp/run/cmdKarl Williamson2022-12-181-5/+9
| | | | | | | | | | | Prior to this commit, when run with PERL_TEST_HARNESS_ASAP, there were three sets of tests run sequentially. The second set consisted of just the comp/, run/, and cmd/ directories. This commit folds those directories and the third set together, which ekes out a bit more performance gain. It was 6% better on my box running ASAN. And, the ASAP runs in about 75% of the time as non-ASAP. There is no change in the non-ASAP operation.
* harness: Run more parallel tests by execution time orderKarl Williamson2022-12-181-12/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In the normal mode of operation of t/harness, there are three sets of tests, where the first set has to completely finish before the second one starts, which has to completely finish before the third set starts. The first set is the basic sanity, and quickly completes. That is untouched by this commit. The third set are the tests for mostly non-core modules, including cpan/, dist/, ext/, and lib/. These are executed so that the longest-running ones are started first when parallel testing is available. That is also unchanged by this commit. The second set is what's left over: generally core tests and ones enabled only on some platforms or by specifying an option, such as torture tests. Prior to this commit, these were executed in parallel, if permitted, but there was no effort to start the longest-running ones first. This results in a less than optimum use of the CPU. The code that orders tests by running time was previously applied to just the third set of tests. Prior commits have extracted out that code into a function. This commit just uses that function for the tests in the second set. In principle, the basic sanity tests could also be run in parallel. This would be easy to do, but I'm a little leery, and since they are quick to execute there would not be much gain in doing so. Comments in the code removed by this commit indicated that the intent was to execute ext/ and lib/ tests last. But that hasn't been true for quite some time, and no one seems to have noticed. Now that we have a function to assemble the tests in a given directory, it would be trivial to change back, but that does lead to a longer wall clock elapsed time. The PERL_TEST_HARNESS_ASAP environment variable is used to change the mode of operation so that most of the tests in the second set are instead moved into the third set. Only the comp/, run/, and cmd tests are left in the second set. That is also unchanged by this commit.
* harness: Extract code into a functionKarl Williamson2022-12-181-88/+96
| | | | | | | | This is in preparation for it being called from a second place in the following commit. The git diff listing shows other code being deleted and added instead of this extraction, because that has a smaller amount of diffs generated
* harness: Move commentsKarl Williamson2022-12-181-4/+4
| | | | | This wasn't done in the previous commit in order to minimize the diff listing
* harness: Improve handling of serial execution exceptionsKarl Williamson2022-12-181-12/+17
| | | | | | | | | | Experience has shown that some directories must be serially executed even though they have no rules indicating so. There are currently 2 such directories, hard-coded as such. This commit turns things into a hash, removing a grep and moves the check to within an already existing loop. If an exception is found, it is deleted from the hash, and at the end, only the non-matched ones remain, so it is trivial to output that these weren't found, which indicastes a likely error.
* harness: Move ARGV, ENV processing earlierKarl Williamson2022-12-181-22/+23
| | | | | | | | This is in preparation for a future commit. That is the purpose of this commit; however, the git difference listing instead shows moving the _extract_tests() function later, because that is the more minimal difference.
* harness: SimplifyKarl Williamson2022-12-181-18/+19
| | | | | By introducing the hash %map_file_to_dir, we can remove an ugly pattern and s/// that were used to derive all the directories.
* harness: Change tabs to spacesKarl Williamson2022-12-181-117/+117
|
* harness: Don't strip off '../' in pathKarl Williamson2022-12-181-3/+4
| | | | This will be useful in future commits
* harness: Assign names to $_Karl Williamson2022-12-181-10/+10
| | | | These are clearer to read, espectially in largish loops.
* harness: Assign name to $2Karl Williamson2022-12-181-1/+2
| | | | It's clearer, and a future commit will destroy $2 before its final use
* harness: There is a .pl test file: cpan/Term-Cap/test.plKarl Williamson2022-12-181-1/+1
| | | | | It was handled by using '*' for that directory, but future commits will want to name individual files in a directory.
* harness: Extract sort into functionKarl Williamson2022-12-181-6/+12
| | | | | This is in preparation for it being called in other places, in a future commit.
* Remove dead VMS code in Cwd::_backtick_pwdCraig A. Berry2022-12-181-2/+1
| | | | | | | | | | | | | | | The code as written would have had no effect since the value in $^O is 'VMS' not 'vms' so it's better to remove the confused and confusing code. _backtick_pwd is not normally called on VMS because it has its own set of routines dispatched via the %METHOD_MAP hash. In the unlikely event that _backtick_pwd got called on VMS, it would either fail because there is no pwd command, or, if running under some Unix emulation environment, work just like Unix, and therefore need no special handling of $ENV{PATH} that is different from Unix.
* regcomp_internal.h - remove typedefYves Orton2022-12-181-2/+3
| | | | | We already typedef scan_data_t in perl.h, we should not do so also in regcomp_internal.h, we just need to defined struct scan_data_t.
* Use VMS absolute path to test taintingCraig A. Berry2022-12-171-1/+1
| | | | | | | | | | | The '"-T" $arg and some suspect arguments' test has been failing because it assumed setting $ENV{PATH} to /usr/bin will pass the absolute path check in mg.c's Perl_magic_setenv, but it doesn't. Using a VMS absolute path gets it passing. Ideally we would be using PL_perllib_sep to figure out whether the list of library paths is in Unix syntax or VMS syntax, but that's not accessible from Perl, so we'll have to assume the test is running with native paths in effect.
* <> to readline documentation updatesScott Baker2022-12-171-1/+1
|
* Detect forbidden flow at compiletime of `defer` or `finally`Paul "LeoNerd" Evans2022-12-175-79/+65
| | | | | | | Using the new `forbid_outofblock_ops()`, many kinds of forbidden control flow out of a `defer` or `finally` block can be detected statically with this function by analysing the optree, rather than leaving it until runtime when the attempt is actually made.
* Add `forbid_outofblock_ops()` to op.cPaul "LeoNerd" Evans2022-12-174-0/+147
| | | | | Adds a new function to statically detect forbidden control flow out of a block.
* File/Glob.xs: Idempotent setting of PL_opfreehook (fixes GH#20615)Paul "LeoNerd" Evans2022-12-172-3/+5
|
* Add proto.h as linguist-generated to .gitattributesPaul "LeoNerd" Evans2022-12-161-0/+1
|
* Define five new operator precedence levelsPaul "LeoNerd" Evans2022-12-166-1401/+1505
| | | | | | | | | | | | Assignment operators (`==`) were missing, as were both the logical and the low-precedence shortcutting OR and AND operators (`&&`, `||`, `and`, `or`) Also renumbered them around somewhat to even out the spacing. This is fine during a development cycle. Also renamed the tokenizer/parser symbol names from "PLUG*OP" to "PLUGIN_*_OP" for better readability.
* Add comment to infix operator precedence enum about when we can/can't change ↵Paul "LeoNerd" Evans2022-12-161-1/+5
| | | | the numbers
* Added function amagic_find(sv, method, flags)Eric Herman2022-12-164-0/+47
| | | | | | | Returns the CV pointer to the overloaded method, which will be needed by join to detect concat magic. Co-authored-by: Philippe Bruhat (BooK) <book@cpan.org>
* Document the meaning of the OPf_SPECIAL flag on the LOOPEX opsPaul "LeoNerd" Evans2022-12-161-0/+2
|
* perldelta.pod - add note about regex engine decompositionYves Orton2022-12-151-1/+3
|
* Write an apidoc fragment for wrap_infix_plugin()Paul "LeoNerd" Evans2022-12-141-0/+21
|
* Token type `pval` should be a void * pointerPaul "LeoNerd" Evans2022-12-145-8/+8
| | | | | | | | | | The `pval` field of the token type union is currently only used in one place; storing the result of the infix operator plugin. Its use here stores a structure pointer, not a string. The union should define this field as a `void *` and not a `char *`. In addition we should not attempt to debug print it as a string because its value is not valid as one.
* Do not cast away constnessBart Van Assche2022-12-136-9/+10
| | | | | | | Fix most compiler warnings caused by building Perl extensions with -Wcast-qual. This is realized by changing the type of multiple T * arguments into const T * and by changing a few (T *) casts into (const T *).
* makedef.pl: Properly define a hash elementKarl Williamson2022-12-101-1/+1
| | | | | | | I had been so used to working lately with C preprocessor directives that I used the same paradigm in Perl without noticing. If 'warnings' had been on, it would have caught this (the previous commit now turns them on).
* makedef.pl: Add 'use warnings'Karl Williamson2022-12-101-0/+1
| | | | This would have saved me a bunch of time.
* makedef.pl: Create $define{WIN32} etcKarl Williamson2022-12-101-5/+11
| | | | | | | | | A portion of makedef.pl must manually be kept in sync with changes to portions of perl.h. Prior to this commit, you had to remember that #ifdef WIN32 from perl.h had to be translated to a completely different paradigm for use in this file. This commit fixes that, which can help prepare the way for future programmatic syncing of the two files.
* makedef.pl: Consistently use constantKarl Williamson2022-12-101-27/+27
| | | | | This script defines a constant 'PLATFORM', but often uses the rhs of that constant. Change to always use the constant.
* Fix warning "implicit declaration of function '_setjmpex'" using MinGW-w64Tsuyoshi Watanabe2022-12-103-2/+4
|
* .github - switch to v3 actionsYves Orton2022-12-091-14/+14
|
* pod/ - document $INC and INCDIRYves Orton2022-12-093-26/+153
|
* pp_ctl.c - move logic closer to where it is usedYves Orton2022-12-091-5/+5
| | | | No sense doing something that has not effect.