This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
perl5.git
11 years agocharnames.t: clarify comments
Karl Williamson [Fri, 10 Sep 2010 16:47:15 +0000 (10:47 -0600)]
charnames.t: clarify comments

11 years agocharnames.t: Don't call srand(undef)
Karl Williamson [Fri, 10 Sep 2010 00:06:22 +0000 (18:06 -0600)]
charnames.t: Don't call srand(undef)

srand(undef) is the same as srand(0).  The code is trying to get random
seeds, not a fixed one.

11 years agocharnames: Remove unnecessary \t in Name.pl
Karl Williamson [Thu, 9 Sep 2010 23:50:16 +0000 (17:50 -0600)]
charnames: Remove unnecessary \t in Name.pl

The double \t\t is unnecessary, and so we can remove one of them,
shortening the table.

11 years agocharnames.pm: Small performance enhancements
Karl Williamson [Thu, 9 Sep 2010 23:16:53 +0000 (17:16 -0600)]
charnames.pm: Small performance enhancements

mktables is changed to output 5 digit code points, which means that
charnames doesn't have to go looking for the boundaries, which gives a
slight performance enhancement.

11 years agomktables: Remove stubbed out code
Karl Williamson [Thu, 9 Sep 2010 22:34:55 +0000 (16:34 -0600)]
mktables: Remove stubbed out code

This commented out code will never be used, as a different solution was
done in charnames.

It was to automatically handle parenthesized character names.  Unicode
is extremely unlikely to ever add new names like this, and all the
existing names are now hard-coded in charnames.pm

11 years agoUse the same $func to Perl_$func macros independent of multiplicity.
Nicholas Clark [Wed, 22 Sep 2010 15:31:16 +0000 (16:31 +0100)]
Use the same $func to Perl_$func macros independent of multiplicity.

The macros of the form #define foo(a, b) Perl_foo(aTHX_ a, b) will also work
under non-multiplicity. There's no issue with adding explicit arguments in
the non-multiplicity case, because it changes one form of compile-time error
into another. (Function Perl_foo passed the wrong number of arguments into
macro foo passed the wrong number of arguments.)

11 years agoMake the new sigtrap.t test more tolerant of OS differences
Father Chrysostomos [Sat, 25 Sep 2010 06:12:00 +0000 (23:12 -0700)]
Make the new sigtrap.t test more tolerant of OS differences

11 years agodefine SvTRUE_nomg for compilers other than gcc
Father Chrysostomos [Sat, 25 Sep 2010 05:22:26 +0000 (22:22 -0700)]
define SvTRUE_nomg for compilers other than gcc

This time I *really* broke the Windows build!

11 years agoperldelta entries for the double-magic fixes [perl #76814]
Father Chrysostomos [Sat, 25 Sep 2010 03:42:54 +0000 (20:42 -0700)]
perldelta entries for the double-magic fixes [perl #76814]

11 years ago[perl #76814] FETCH called twice - y
Father Chrysostomos [Sat, 25 Sep 2010 03:33:47 +0000 (20:33 -0700)]
[perl #76814] FETCH called twice - y

This patch stops y from calling get-magic twice. (This has caused
double magick since as far back as 5.6.2.)

11 years ago[perl #76814] FETCH called twice - m and s
Father Chrysostomos [Sat, 25 Sep 2010 03:33:42 +0000 (20:33 -0700)]
[perl #76814] FETCH called twice - m and s

This fixes m and s. It modifies pp_regcomp to avoid extra magic. It
also corrects a bug in sv_catsv_flags, which would still call
mg_get(ssv) even without the SV_GMAGIC flag set.

11 years ago[perl #76814] FETCH called twice - !
Father Chrysostomos [Sat, 25 Sep 2010 03:33:03 +0000 (20:33 -0700)]
[perl #76814] FETCH called twice - !

This fixes ! by changing sv_2bool to sv_2bool_flags (with a macro
wrapper) and adding SvTRUE_nomg. It also corrects the docs that state
incorrectly that SvTRUE does not handle magic.

11 years ago[perl #76814] FETCH called twice - string comparison ops
Father Chrysostomos [Sat, 25 Sep 2010 03:31:28 +0000 (20:31 -0700)]
[perl #76814] FETCH called twice - string comparison ops

This patch changes sv_eq, sv_cmp, sv_cmp_locale and sv_collxfrm
to _flags forms, with macros under the old names for sv_eq and
sv_collxfrm, but functions for sv_cmp* since pp_sort.c needs them.

11 years agoCommitting the current freeze and release plan for 5.14. khw++ for
Jesse Vincent [Fri, 24 Sep 2010 23:20:29 +0000 (19:20 -0400)]
Committing the current freeze and release plan for 5.14.  khw++ for
noticing that I'd failed to do this after conference season.

11 years agoFis various Math::BigInt spelling mistakes
gregor herrmann [Fri, 24 Sep 2010 20:17:34 +0000 (22:17 +0200)]
Fis various Math::BigInt spelling mistakes

11 years ago[perl #78000] [PATCH] Upgrade to threads 1.79
Jerry D. Hedden [Fri, 24 Sep 2010 20:42:04 +0000 (21:42 +0100)]
[perl #78000] [PATCH] Upgrade to threads 1.79

  Attached is a revised patch to upgrade to v1.79.  I needed to fix
  the tests in the newly added t/kill2.t file.  The blead version will
  be 1.79_01.

11 years agoModify a utf8.t test in anticipation of a fix for [perl #74022]
Father Chrysostomos [Fri, 24 Sep 2010 19:28:36 +0000 (12:28 -0700)]
Modify a utf8.t test in anticipation of a fix for [perl #74022]

In anticipation of a fix for [perl #74022], this patch corrects the
test for q·foo· in utf8.t to use ¡ instead of ·. I’ve also moved the
test outside of the eval, so it will still run (and fail) if the com-
pilation fails, instead of causing an invalid test count.

11 years agofix typo in perl5135delta
David Golden [Fri, 24 Sep 2010 18:03:49 +0000 (18:03 +0000)]
fix typo in perl5135delta

11 years agoperldelta: Note Perl version of regexp_pattern()
Karl Williamson [Fri, 24 Sep 2010 14:46:12 +0000 (08:46 -0600)]
perldelta: Note Perl version of regexp_pattern()

perldelta suggests using this, but it didn't come into being until
5.9.5, so cpan modules may not be able to use it.

11 years agoAdd a warning to test.pl if quotes are used in one-liners.
Nicholas Clark [Fri, 24 Sep 2010 10:46:41 +0000 (11:46 +0100)]
Add a warning to test.pl if quotes are used in one-liners.

Fix all the tests that were using quotes, and (by implication) working
because barewords are treated as strings, and one-liners aren't run under
strict.

11 years agoAvoid using double quotes in a one-liner runperl.
Nicholas Clark [Fri, 24 Sep 2010 10:22:24 +0000 (11:22 +0100)]
Avoid using double quotes in a one-liner runperl.

test.pl uses "" for command line quoting on Win32, VMS and NetWare, '' on *nix.
Hence what "works on my machine" on *nix may not work elsewhere.

11 years agosigtrap version bump + perldelta
Father Chrysostomos [Fri, 24 Sep 2010 07:45:35 +0000 (00:45 -0700)]
sigtrap version bump + perldelta

11 years agoMissing link in perldelta
Father Chrysostomos [Fri, 24 Sep 2010 07:42:32 +0000 (00:42 -0700)]
Missing link in perldelta

11 years agoAdd tests for [perl #72340] sigtrap attempts to modify read-only thing
Father Chrysostomos [Fri, 24 Sep 2010 07:34:04 +0000 (00:34 -0700)]
Add tests for [perl #72340] sigtrap attempts to modify read-only thing

11 years ago[perl #72340] sigtrap attempts to modify read-only thingy
Joshua N Pritikin [Fri, 24 Sep 2010 07:23:46 +0000 (00:23 -0700)]
[perl #72340] sigtrap attempts to modify read-only thingy

No much to say. sigtrap otherwise attempts to modify a
read-only thingy. Patch below solves it for me.

11 years agoAdd Joshua Pritikin’s other e-mail address to checkAUTHORS.pl
Father Chrysostomos [Fri, 24 Sep 2010 07:22:11 +0000 (00:22 -0700)]
Add Joshua Pritikin’s other e-mail address to checkAUTHORS.pl

11 years agoThe rest of [perl #71710] fixes for File::Find
Alex Davies [Fri, 24 Sep 2010 07:12:27 +0000 (00:12 -0700)]
The rest of [perl #71710] fixes for File::Find

The code is from Alex Davies. The commit message is from the committer.

Somehow I only ended up with half the patch applied. No tests failed
for me, because these code paths are only reached on Windows, which,
thankfully, I am not using.

Hopefully this will eliminate the smoke that is already pouring in....

(It’s *my* turn to break blead for Windows. :-)

11 years agoOops. I broke sigtrap.t’s test output
Father Chrysostomos [Fri, 24 Sep 2010 07:03:23 +0000 (00:03 -0700)]
Oops. I broke sigtrap.t’s test output

11 years agoRename isALNUM_L1 to isWORDCHAR_L1
Karl Williamson [Fri, 24 Sep 2010 06:24:18 +0000 (23:24 -0700)]
Rename isALNUM_L1 to isWORDCHAR_L1

11 years agoConvert sigtrap.t to test.pl
Father Chrysostomos [Fri, 24 Sep 2010 06:08:18 +0000 (23:08 -0700)]
Convert sigtrap.t to test.pl

11 years agohandy.h: Add isALNUM_L1() macro
Karl Williamson [Thu, 23 Sep 2010 18:16:12 +0000 (12:16 -0600)]
handy.h: Add isALNUM_L1() macro

This is a synonym for isALNUMU

11 years agoSubject: handy.h: Add isSPACE_L1 with Unicode semantics
Karl Williamson [Thu, 23 Sep 2010 17:32:13 +0000 (11:32 -0600)]
Subject: handy.h: Add isSPACE_L1 with Unicode semantics

11 years agoperldelta: Give better instructions about (?^...)
Karl Williamson [Fri, 24 Sep 2010 01:50:34 +0000 (19:50 -0600)]
perldelta: Give better instructions about (?^...)

Avar pointed out that there is an existing API wwhich helps in coping
with this

11 years agoperldelta entry for File::DosGlob
Father Chrysostomos [Fri, 24 Sep 2010 05:15:02 +0000 (22:15 -0700)]
perldelta entry for File::DosGlob

11 years ago[perl #71712] fixes for File::DosGlob
Alex Davies [Fri, 24 Sep 2010 05:08:28 +0000 (22:08 -0700)]
[perl #71712] fixes for File::DosGlob

The changes are

1. Allow for parentheses in glob pattern.
2. Strip redundant "./" from drive relative glob patterns results.

11 years ago* Fixed output for lex-like scanners example in perlop
brian d foy [Fri, 24 Sep 2010 01:43:00 +0000 (20:43 -0500)]
* Fixed output for lex-like scanners example in perlop
     This should probably be given-when instead of a naked block
     and a redo

11 years agoperlfaa4: fix a one-off mistake
brian d foy [Fri, 24 Sep 2010 01:34:08 +0000 (20:34 -0500)]
perlfaa4: fix a one-off mistake
    + How do I perform an operation on a series of integers?

11 years agoperldelta entry for File::Find
Father Chrysostomos [Fri, 24 Sep 2010 00:45:59 +0000 (17:45 -0700)]
perldelta entry for File::Find

11 years ago[perl #71710] fixes for File::Find
Alex Davies [Fri, 24 Sep 2010 00:23:49 +0000 (17:23 -0700)]
[perl #71710] fixes for File::Find

Please find attached patches for File::Find and its test file.

These changes ensure that paths passed to File::Find::find() on Win32
which have a trailing *back*slash are neatly handled. That is, the
change ensures paths such as c:\dir\/file are no longer generated.

11 years agoUpdated Unicode-Collate to CPAN version 0.60
Chris 'BinGOs' Williams [Thu, 23 Sep 2010 16:46:43 +0000 (17:46 +0100)]
Updated Unicode-Collate to CPAN version 0.60

  [DELTA]

  0.60  Thu Sep 23 21:37:36 2010
    - bug fix: index() [and its friends including gmatch()] didn't remove
      ignorable characters in the substring correctly.
      Thanks for the bug report:
   http://www.xray.mpe.mpg.de/mailing-lists/perl-unicode/2010-09/msg00014.html

    - U::C::Locale newly supports locales: de__phonebook, nso, om, tn, vi.
    - precomposites of a-breve, a-circ, e-circ, o-circ are tailored as well.
        (affected locales: ro, sk, sv)

11 years agoAdd default safe guesses for static_inline to plan9 files.
Andy Dougherty [Thu, 23 Sep 2010 16:06:10 +0000 (12:06 -0400)]
Add default safe guesses for static_inline to plan9 files.

11 years agoAdd static inline values to canned Netware/config_H.wc file.
Andy Dougherty [Thu, 23 Sep 2010 15:59:47 +0000 (11:59 -0400)]
Add static inline values to canned Netware/config_H.wc file.

11 years agoUpdate canned win32/config_H.* files with static inline values
Andy Dougherty [Thu, 23 Sep 2010 15:55:28 +0000 (11:55 -0400)]
Update canned win32/config_H.* files with static inline values
to match the canned win32/config.* settings.  For .bc and
.ce, we still have a plain 'static'.  Better settings from
knowledgeable users about those platforms would be welcome.

11 years agoUpdate static_inline guesses in win32/config.[gv]c*
Andy Dougherty [Thu, 23 Sep 2010 15:53:16 +0000 (11:53 -0400)]
Update static_inline guesses in win32/config.[gv]c*

For gcc, assume all variants used on Win32 will support
static __inline__.  VC already had static __inline.
Update VC64 to match.

11 years agoSome tests for Perl_grok_number().
Nicholas Clark [Thu, 23 Sep 2010 14:16:05 +0000 (15:16 +0100)]
Some tests for Perl_grok_number().

Not yet comprehensive - only tests the integer conversion code paths.

11 years agoSet default static inline for Netware/config.wc.
Andy Dougherty [Thu, 23 Sep 2010 14:07:41 +0000 (10:07 -0400)]
Set default static inline for Netware/config.wc.

If anyone knows how to support static inline on Netware,
a patch would be appreciated.

11 years agoAdd default setting of perl_static_inline='static' to all win32 configs.
Andy Dougherty [Thu, 23 Sep 2010 13:56:11 +0000 (09:56 -0400)]
Add default setting of perl_static_inline='static' to all win32 configs.

Win32 users who know better are invited to change the definitions
as appropriate, but this should at least allow it to build.

11 years agoSet d_static_inline for win32/config.vc, since VC supports static __inline.
Andy Dougherty [Thu, 23 Sep 2010 13:53:43 +0000 (09:53 -0400)]
Set d_static_inline for win32/config.vc, since VC supports static __inline.

11 years agoMake dquote_static.c available to ext/re/
Tony Cook [Thu, 23 Sep 2010 10:44:37 +0000 (20:44 +1000)]
Make dquote_static.c available to ext/re/

Under Win32 the main perl source directory isn't in the C include
path, so as we do with the re source files, copy dquote_static.c to
the ext/re directory.

11 years agoConfigure inline support for 32-bit VC++
Tony Cook [Thu, 23 Sep 2010 10:43:44 +0000 (20:43 +1000)]
Configure inline support for 32-bit VC++

VC supports static inline via "static __inline".

11 years ago[perl #71806] perldb does not setup %dbline with the shebang option -d
Father Chrysostomos [Thu, 23 Sep 2010 08:38:10 +0000 (01:38 -0700)]
[perl #71806] perldb does not setup %dbline with the shebang option -d

The first time gv_fetchfile is called for a particular file, it
creates the glob and, if debugging is on, creates an AV. If the glob
already exists (i.e., in subsequent calls), the AV is not created. The
attached patch moves the check for debugging mode and the creation of
the AV outside the if-block that checks whether the glob exists.

This bug seems to have existed for a very long time and has been
intermittent. It seems that many different things can change the order
in which #!perl -d and gv_fetchfile occur. Whether compilation options
affect it I do not know. I can reproduce it in 5.6.2, 5.8.[123456]
(non-threaded) and 5.11.3 (both threaded and non-threaded), but not
5.8.[789] or 5.10.[01] (threaded).

11 years agoperldelta for bug #70615 + tweaks
Father Chrysostomos [Thu, 23 Sep 2010 08:01:20 +0000 (01:01 -0700)]
perldelta for bug #70615 + tweaks

11 years agoFix code-before-declaration problem in universal.c
Steve Hay [Thu, 23 Sep 2010 07:28:32 +0000 (08:28 +0100)]
Fix code-before-declaration problem in universal.c

11 years ago[perl #70614] Seg. fault with eval/use/UNITCHECK/DESTROY/eval combination
Father Chrysostomos [Thu, 23 Sep 2010 06:47:11 +0000 (23:47 -0700)]
[perl #70614] Seg. fault with eval/use/UNITCHECK/DESTROY/eval combination

This case can be reduced to:
eval "UNITCHECK{ eval 0 }"

(eval 0 triggers the bug more reliably than eval ''.)

The inner eval clobbers PL_eval_start, so when the UNITCHECK finishes,
the outer eval tries to call the inner eval’s code, which has been
freed already.

This commit saves PL_eval_start and restores it after UNITCHECK.

11 years agoRemove unneeded 'use' from ext/XS-APItest/t/peep.t Devel::Peek is not used by ext...
Jerry D. Hedden [Wed, 22 Sep 2010 20:36:14 +0000 (16:36 -0400)]
Remove unneeded 'use' from ext/XS-APItest/t/peep.t Devel::Peek is not used by ext/XS-APItest/t/peep.t, so remove it from the test code.

11 years agoregcomp.c: Convert some things to use cBOOL()
Karl Williamson [Tue, 21 Sep 2010 21:09:12 +0000 (15:09 -0600)]
regcomp.c: Convert some things to use cBOOL()

11 years agore.pm: Change comment to use new (?^...)
Karl Williamson [Tue, 21 Sep 2010 01:16:24 +0000 (19:16 -0600)]
re.pm: Change comment to use new (?^...)

11 years agoAdd /d, /l, /u (infixed) regex modifiers
Karl Williamson [Tue, 21 Sep 2010 00:57:24 +0000 (18:57 -0600)]
Add /d, /l, /u (infixed) regex modifiers

This patch adds recognition of these modifiers, with appropriate action
for d and l.  u does nothing useful yet.  This allows for the
interpolation of a regex into another one without losing the character
set semantics that it was compiled with, as for the first time, the
semantics is now specified in the stringification as one of these
modifiers.

To this end, it allocates an unused bit in the structures.  The off-
sets change so as to not disturb other bits.

11 years agoChange .t to use new (?^...)
Karl Williamson [Tue, 21 Sep 2010 00:31:00 +0000 (18:31 -0600)]
Change .t to use new (?^...)

There is a line in this .t which uses the old regex stringification.
The contents are not currently tested for, but for cleanliness, change
to the new.

11 years agoChange comments, documentation for new (?^...)
Karl Williamson [Tue, 21 Sep 2010 00:29:59 +0000 (18:29 -0600)]
Change comments, documentation for new (?^...)

I overlooked these earlier in adding the caret notation.

11 years agoChange to use mnemonic instead of char constant
Karl Williamson [Tue, 21 Sep 2010 00:26:33 +0000 (18:26 -0600)]
Change to use mnemonic instead of char constant

The new '^' in (?^...) should really be a macro.

11 years agohandy.h: isASCII() extend to work on > 8 bit values
Karl Williamson [Sun, 19 Sep 2010 18:29:02 +0000 (12:29 -0600)]
handy.h: isASCII() extend to work on > 8 bit values

Prior to this patch, if isASCII() is called with something like '256',
it would return true.

For some reason unknown to me, U64 is defined only inside the perl core.
However, the equivalent U64TYPE is known everywhere, so in the macro
that can be called outside of core, use that instead.

The commit log doesn't give a reason for not defining U64 outside of
core, and no tests in the suite fail when it is defined outside core.
But out of caution, I'm just doing this workaround instead of exposing
U64.

11 years agohandy.h: Don't use isascii() as not in all libc's
Karl Williamson [Sun, 19 Sep 2010 17:57:04 +0000 (11:57 -0600)]
handy.h: Don't use isascii() as not in all libc's

EBCDIC platforms use isascii(), but is not in all libc's so better to
use our own.

11 years agohandy.h: Fix-up documentation
Karl Williamson [Sun, 19 Sep 2010 17:04:34 +0000 (11:04 -0600)]
handy.h: Fix-up documentation

Previous documentation was wrong for EBCDIC platforms.  This fixes that
and adds some more explanation.

11 years agohandy.h: toUPPER is not a char class fcn
Karl Williamson [Sun, 19 Sep 2010 16:38:14 +0000 (10:38 -0600)]
handy.h: toUPPER is not a char class fcn

toUPPER() and toLOWER() were grouped with the character class functions
(in perlapi), to which they are related, but aren't the same.  Create a
new heading for these.

11 years agoautodoc.pl: Allow heading level documentation
Karl Williamson [Sun, 19 Sep 2010 16:20:58 +0000 (10:20 -0600)]
autodoc.pl: Allow heading level documentation

This patch changes autodoc.pl to accept text that is to come immediately
after headings, so that it applies to across the whole section, and not
just to an individual function within that section.

11 years agoAdd lib to @INC in t/base/rs.t
Father Chrysostomos [Wed, 22 Sep 2010 20:10:19 +0000 (13:10 -0700)]
Add lib to @INC in t/base/rs.t

t/base/rs.t needs to @INClude the lib directory before requiring
PerlIO::scalar, even if the require is in an eval, because it will
otherwise pick up a previously-installed copy.

Since 87b9e1600 (Eliminate PL_* accessor functions under ithreads), a
binary-incompatible change, I’ve been getting these errors:

t/base/rs......................................................dyld: lazy symbol binding failed: Symbol not found: _Perl_Istack_sp_ptr
  Referenced from: /usr/local/lib/perl5/5.13.5/darwin-thread-multi-2level/auto/PerlIO/scalar/scalar.bundle
  Expected in: dynamic lookup

dyld: Symbol not found: _Perl_Istack_sp_ptr
  Referenced from: /usr/local/lib/perl5/5.13.5/darwin-thread-multi-2level/auto/PerlIO/scalar/scalar.bundle
  Expected in: dynamic lookup

FAILED--no leader found
Failed a basic test (base/rs.t) -- cannot continue.
make: *** [test] Error 255

11 years agoRun perl regen.pl after removing regcurly from embed.fnc.
Andy Dougherty [Wed, 22 Sep 2010 17:45:47 +0000 (13:45 -0400)]
Run perl regen.pl after removing regcurly from embed.fnc.

Since regcurly is now a static inline function, it no longer
needs to appear in embed.fnc.  embed.pl doesn't quite have the
right flags to deal with static inline functions, so I just
removed regcurly entirely.  It's not for embedding or exporting
anyway.

11 years agoExtract regcurly as a static inline function.
Andy Dougherty [Wed, 22 Sep 2010 17:44:36 +0000 (13:44 -0400)]
Extract regcurly as a static inline function.

This patch extracts regcurly from regcomp.c and converts it
to a static inline function in a new file dquote_static.c
that is now #included by regcomp.c and toke.c.  This change
will require 'make regen'.

11 years agoRemove @extvars from embed.pl
Nicholas Clark [Wed, 22 Sep 2010 16:32:15 +0000 (17:32 +0100)]
Remove @extvars from embed.pl

It's been unused since PERL_POLLUTE was removed in cfef31b27d1a56cd.

11 years agoAdd missing newline to macro_to_ifndef in ExtUtils::Constant::Base
Jerry D. Hedden [Wed, 22 Sep 2010 13:17:14 +0000 (09:17 -0400)]
Add missing newline to macro_to_ifndef in ExtUtils::Constant::Base

11 years agoIn embed.pl, replace C<$ret .=> with C<$ret => when we know that $ret is "".
Nicholas Clark [Wed, 22 Sep 2010 15:05:40 +0000 (16:05 +0100)]
In embed.pl, replace C<$ret .=> with C<$ret => when we know that $ret is "".

Remove one unnecessary initialisation of $ret to "", when all code paths beyond
assign to it. Remove one $ret completely (from &write_global_sym).

11 years agoRemove &munge_c_files from embed.pl, as it has never been used.
Nicholas Clark [Wed, 22 Sep 2010 14:25:17 +0000 (15:25 +0100)]
Remove &munge_c_files from embed.pl, as it has never been used.

It was added, with the only call to it commented out, in cea2e8a9dd23747f.
This means that walk_table's support for undef meaning 'no output' can
removed.

11 years agoEmit $_ to Perl_$_ for "nocontext" functions under multiplicity.
Nicholas Clark [Wed, 22 Sep 2010 14:04:00 +0000 (15:04 +0100)]
Emit $_ to Perl_$_ for "nocontext" functions under multiplicity.

(Strictly for all functions with variable arguments, but *no* explicit
interpreter context arguments. Most of these are *_nocontext.)

We're already emitting macros for the non-multiplicity case, and as these
functions don't need an aTHX_ adding, there's no C portability reason why
we can't generate them here too. So do so, for consistency.

11 years agoIn embed.pl, refactor walk_table to simplify its arguments.
Nicholas Clark [Wed, 22 Sep 2010 13:21:11 +0000 (14:21 +0100)]
In embed.pl, refactor walk_table to simplify its arguments.

No need to pass in leader and have it default to do_not_edit ($filename),
as the only time the leader is needed is for the case of explicit open file
by name. Use undef instead of '/dev/null' to signal that no output is desired.

11 years agoEnsure regen.pl and the scripts that it calls can be run by older perls.
Nicholas Clark [Wed, 22 Sep 2010 12:50:20 +0000 (13:50 +0100)]
Ensure regen.pl and the scripts that it calls can be run by older perls.

As the internal comments state, they may be all that is available, particularly
if trying to port something to an obscure platform. There's not that much that
needs changing to get back to 5.005, or from there to 5.004, but beyond there
is hard work, and really not worth it.

11 years agoIn embed.pl's walk_table, the default filename of '-' was never used.
Nicholas Clark [Wed, 22 Sep 2010 09:49:24 +0000 (10:49 +0100)]
In embed.pl's walk_table, the default filename of '-' was never used.

Remove it, simplifying the argument passing.

11 years agoProgrammatically generate the compatibility macros for "misnamed functions".
Nicholas Clark [Wed, 22 Sep 2010 09:03:13 +0000 (10:03 +0100)]
Programmatically generate the compatibility macros for "misnamed functions".

Add a new flag 'O' in embed.fnc to generate a macro mapping perl_$func() to
$func(). The macro for call_atexit() is far too special to do this way.

11 years agoRemove from warnings.pl various long commented out and dead code.
Nicholas Clark [Wed, 22 Sep 2010 11:05:19 +0000 (12:05 +0100)]
Remove from warnings.pl various long commented out and dead code.

This code was commented out/rendered vestigial in 1998, 2000 and 2002 by
599cee73f2261c5ed3a7d8c7d7e4d69d and 0d658bf5a06395c2.

11 years agoFix misinformation in perldebtut
Florian Ragwitz [Wed, 22 Sep 2010 07:30:25 +0000 (09:30 +0200)]
Fix misinformation in perldebtut

'B' is for removing breakpoints, not 'd' or 'D'. Pointed out by Jerry Huth.

11 years agoWe're going to embed two interpreters, not four
Florian Ragwitz [Tue, 21 Sep 2010 11:29:06 +0000 (13:29 +0200)]
We're going to embed two interpreters, not four

11 years agomake sure perl doesn't touch stat.t between stats
Tony Cook [Wed, 22 Sep 2010 04:28:36 +0000 (14:28 +1000)]
make sure perl doesn't touch stat.t between stats

ebcfa0534 changed stat.t to avoid using TEST as the stat target, since
it is read by other test scripts.  But with the initial stat() in the
BEGIN block perl is still reading the script for compilation, which
will update the access time.  Since the system clock usually didn't
tick another second between the first and second stats, the test
usually succeeded, but occasionally the clock would tick, and the test
would fail.

Moved the stat() out of the BEGIN block to avoid that.

As a check I temporarily added a 2 second sleep after the initial
stat to ensure we didn't have a similar problem to that will
allowed this to pass most of the time.

11 years ago‘criteria was’ -> ‘criteria were’
Father Chrysostomos [Tue, 21 Sep 2010 23:23:11 +0000 (16:23 -0700)]
‘criteria was’ -> ‘criteria were’

11 years agoProgrammatically generate embed.h's *_nocontext exception list in embed.pl.
Nicholas Clark [Tue, 21 Sep 2010 16:06:27 +0000 (17:06 +0100)]
Programmatically generate embed.h's *_nocontext exception list in embed.pl.

Previously the list was hard-coded.

11 years agoIn embed.pl, read embed.fnc into an array, rather than seeking and rereading.
Nicholas Clark [Tue, 21 Sep 2010 15:31:41 +0000 (16:31 +0100)]
In embed.pl, read embed.fnc into an array, rather than seeking and rereading.

11 years agoIn embed.pl, %vfuncs has been unused since PERL_OBJECT was removed in 2001.
Nicholas Clark [Tue, 21 Sep 2010 14:49:53 +0000 (15:49 +0100)]
In embed.pl, %vfuncs has been unused since PERL_OBJECT was removed in 2001.

PERL_OBJECT was removed in commit acfe0abcedaf592f. No point in keeping dead
code.

11 years agoExtUtils::Constant::ProxySubs should use mro_method_changed_in() if available.
Nicholas Clark [Tue, 21 Sep 2010 14:11:17 +0000 (15:11 +0100)]
ExtUtils::Constant::ProxySubs should use mro_method_changed_in() if available.

11 years agoAdd macro_to_ifndef to ExtUtils::Constant::Base, and use it in place of #else
Nicholas Clark [Tue, 21 Sep 2010 13:55:52 +0000 (14:55 +0100)]
Add macro_to_ifndef to ExtUtils::Constant::Base, and use it in place of #else

Previously the code was using the #ifdef generated by macro_to_ifdef(), and
immediately following that with an #else. That was ugly. And longer.

11 years agoTweak ExtUtils::Constant::ProxySubs to use hv_exists_ent().
Nicholas Clark [Tue, 21 Sep 2010 13:27:19 +0000 (14:27 +0100)]
Tweak ExtUtils::Constant::ProxySubs to use hv_exists_ent().

Previously it was using hv_exists(), requiring extra code to unpack the SV and
convert it to the correct string form for the hash API.

11 years agoRemove boilerplate and (un)conditional code from Makefile.PLs in ext
Nicholas Clark [Tue, 21 Sep 2010 13:07:00 +0000 (14:07 +0100)]
Remove boilerplate and (un)conditional code from Makefile.PLs in ext

11 years agoTweak XS::APItest to automatically add all functions to @EXPORT.
Nicholas Clark [Tue, 21 Sep 2010 12:34:12 +0000 (13:34 +0100)]
Tweak XS::APItest to automatically add all functions to @EXPORT.

This saves manually maintaining the export list, which is makework given that
the module is only used by its own tests. As the export now folds in symbols
from subpackages, this will allow refactoring/reordering/rationalisation of
the layout of testing routines in it.

11 years agoEliminate PL_* accessor functions under ithreads.
Nicholas Clark [Thu, 19 Aug 2010 14:54:12 +0000 (15:54 +0100)]
Eliminate PL_* accessor functions under ithreads.

When MULTIPLICITY was first developed, and interpreter state moved into an
interpreter struct, thread and interpreter local PL_* variables were defined
as macros that called accessor functions, returning the address of the value,
outside of the perl core. The intent was to allow members within the
interpreter struct to change size without breaking binary compatibility, so
that bug fixes could be merged to a maintenance branch that necessitated such
a size change.

However, some non-core code defines PERL_CORE, sometimes intentionally to
bypass this mechanism for speed reasons, sometimes for other reasons but with
the inadvertent side effect of bypassing this mechanism. As some of this code
is widespread in production use, the result is that the core *can't* change
the size of members of the interpreter struct, as it will break such modules
compiled against a previous release on that maintenance branch. The upshot
is that this mechanism is redundant, and well-behaved code is penalised by
it. Hence it can and should be removed.

Accessor functions are still needed for globals when PERL_GLOBAL_STRUCT is
defined.

11 years agoClarify a perldelta entry
Father Chrysostomos [Tue, 21 Sep 2010 07:31:58 +0000 (00:31 -0700)]
Clarify a perldelta entry

11 years agoperldelta entries for the last two bug fixes
Father Chrysostomos [Tue, 21 Sep 2010 07:07:21 +0000 (00:07 -0700)]
perldelta entries for the last two bug fixes

11 years agoMention wide character warnings in perl5135delta.pod
Father Chrysostomos [Tue, 21 Sep 2010 06:51:40 +0000 (23:51 -0700)]
Mention wide character warnings in perl5135delta.pod

An oversight: warn and die now produced wide character warnings, as
well as print.

This commit adds them to perl5135delta.pod retroactively, so they will
make their way into perl5140delta.pod.

11 years agoFix pod syntax in perlsub
Father Chrysostomos [Tue, 21 Sep 2010 05:51:39 +0000 (22:51 -0700)]
Fix pod syntax in perlsub

11 years ago[perl #47365] Docs for \$ prototypes
Father Chrysostomos [Tue, 21 Sep 2010 05:29:03 +0000 (22:29 -0700)]
[perl #47365] Docs for \$ prototypes

\$ allows any hash/array element, even if it does not start with a
dollar sign.

11 years agoTest localization of English.pm’s $LIST_SEPARATOR [perl #47107]
Michael G Schwern [Tue, 21 Sep 2010 05:23:48 +0000 (22:23 -0700)]
Test localization of English.pm’s $LIST_SEPARATOR [perl #47107]

11 years agoLet B::Deparse know about the [perl #20444] fix.
Father Chrysostomos [Tue, 21 Sep 2010 05:05:39 +0000 (22:05 -0700)]
Let B::Deparse know about the [perl #20444] fix.

With the previous commit:

$ ./perl -Ilib -MO=Deparse -e'"foo" =~ (1?/foo/:/bar/)'
'foo' =~ /foo/;
-e syntax OK

So the Deparse output no longer matches what perl does. With
this commit:

$ ./perl -Ilib -MO=Deparse -e'"foo" =~ (1?/foo/:/bar/)'
'foo' =~ ($_ =~ /foo/);
-e syntax OK

11 years ago[perl #20444] regex not evaluated in constant ?:
Father Chrysostomos [Tue, 21 Sep 2010 05:05:34 +0000 (22:05 -0700)]
[perl #20444] regex not evaluated in constant ?:

  $text =~ ( 1 ? /phoo/ : /bear/)

used to be constant-folded to

  $text =~ /phoo/

This patch solves the problem by marking match and subst ops as
OPf_SPECIAL during constant folding, so the =~ operator can tell not
to take possession of it.