Rafael Garcia-Suarez [Wed, 18 Mar 2009 19:20:17 +0000]
Smart match when a hash is on the RHS
This implement the new semantics of C<~~ HASH> smart matching.
This also reveals that overloading actually does not work at all.
Add also tests for C<undef ~~ %hash>.
Rafael Garcia-Suarez [Wed, 18 Mar 2009 19:12:47 +0000]
Reverse the order of operands for several "~~ hash" tests
This way the hash is on the right.
Some of those tests will need to become symmetrical later.
Rafael Garcia-Suarez [Wed, 18 Mar 2009 18:29:34 +0000]
Remove obsolete or redundant tests
Rafael Garcia-Suarez [Tue, 17 Mar 2009 14:34:24 +0000]
Document that empty sets don't smart-match
(and implement this for the C<~~ coderef> form)
Rafael Garcia-Suarez [Tue, 17 Mar 2009 14:11:05 +0000]
Test that in "~~ sub", the sub is not called on empty hashes and arrays
Rafael Garcia-Suarez [Tue, 17 Mar 2009 13:34:46 +0000]
Fix a warnings test that was failing due to smart match dispatch changes
Rafael Garcia-Suarez [Tue, 17 Mar 2009 09:31:45 +0000]
Iterative smart match over keys/elements when a coderef is on the RHS
Rafael Garcia-Suarez [Fri, 13 Mar 2009 10:47:58 +0000]
Make smart matching ~~ undef dispatch only on the RHS
Rafael Garcia-Suarez [Thu, 12 Mar 2009 09:55:44 +0000]
Some tests reorgarnisation for ~~ against undef and objects
Rafael Garcia-Suarez [Fri, 6 Mar 2009 14:57:21 +0000]
Remove special case for coderefs with empty prototypes in smart match
(plus, fix a metasyntactic name clash in the switch test)
Rafael Garcia-Suarez [Fri, 6 Mar 2009 14:01:34 +0000]
Make the "..." flip-flop operator work in scalar context in when()
Rafael Garcia-Suarez [Wed, 4 Mar 2009 20:14:10 +0000]
The new smart match dispatch table for 5.10.1 onwards
This /does/ break backwards compatibility. Changes to come are:
- ~~ is no longer commutative. Dispatch is now done based on the
(run-time) type of the right side argument.
- The right side can be a ".." range, which will be treated specially,
and no longer as a boolean operator (as in scalar context).
- when() should treat "..." as a boolean operator.
- Coderefs with an empty prototype are no longer special.
- Any ~~ Array distributes the smart match test.
- Comparing two coderefs is no longer a special case and does not
perform referential equality. (Use \&foo ~~ "".\&bar for that.)
This patch also documents that ~~ won't work on objects that don't
overload it, except in the expression $object ~~ undef.
Rafael Garcia-Suarez [Wed, 4 Mar 2009 19:40:59 +0000]
Remove TODO tests about && in when() clauses
when() actually behaves as documented in perlsyn. It treats "E1 && E2"
expressions as booleans only if E1 is boolean, and if not, it does the
equivalent of the smart match expression "$_ ~~ (E1 && E2)". As long as
the ~~ operator is not expected to distribute boolean expressions found
on its right side, the current behaviour of perl is correct.
So, should we expect ~~ to distribute boolean expressions ? Given that
this would be rather complex to implement and test correctly with
complex expressions, given that we don't expect =~ to distribute either,
and given that when() is already quite smart regarding boolean
operators, I see no motivation for that feature.
This allows to close bug #50538 as "won't fix".
Rafael Garcia-Suarez [Wed, 4 Mar 2009 18:40:59 +0000]
Document that when() treats specially most of the filetest operators
Rafael Garcia-Suarez [Wed, 4 Mar 2009 18:33:31 +0000]
Make // behave like || in when clauses
(plus minor documentation updates about "when")
Jos I. Boumans [Wed, 4 Mar 2009 12:04:19 +0000]
Update Archive::Extract to 0.31_02
Alex Vandiver [Wed, 4 Mar 2009 07:54:26 +0000]
Add a failing test for stack corruption with MULTICALL
Steffen Mueller [Tue, 3 Mar 2009 20:18:30 +0000]
Update Parse::CPAN::Meta to 0.04_01
Steffen Mueller [Tue, 3 Mar 2009 20:25:27 +0000]
Add Parse::CPAN::Meta to Porting/Maintainers.pl
Steffen Mueller [Tue, 3 Mar 2009 20:19:59 +0000]
Add contact info for Simon Wistow in Porting/Maintainers.pl
Rafael Garcia-Suarez [Tue, 3 Mar 2009 15:57:06 +0000]
Remove the MANIFEST from Compress-Raw-Bzip2
(it wasn't the same in the CPAN distribution anyway)
Rafael Garcia-Suarez [Mon, 2 Mar 2009 14:05:40 +0000]
Bump versions to 0.12 to sync with CPAN version
Steffen Mueller [Tue, 6 Jan 2009 18:49:01 +0000]
Integrate Parse::CPAN::Meta 0.04 into core
Jos I. Boumans [Fri, 27 Feb 2009 15:07:53 +0000]
Update CPANPLUS to 0.85_06
Rafael Garcia-Suarez [Mon, 2 Mar 2009 09:44:54 +0000]
Bump versions to 0.10 for CPAN sync
Rafael Garcia-Suarez [Sun, 1 Mar 2009 23:13:34 +0000]
Make util.c compile on systems without getcwd()
Rafael Garcia-Suarez [Sun, 1 Mar 2009 23:05:03 +0000]
Better gitignore file for Compress-Raw-Bzip2
Rafael Garcia-Suarez [Sun, 1 Mar 2009 22:37:53 +0000]
Add Compress-Raw-Bzip2, by Paul Marquess
Rafael Garcia-Suarez [Sun, 1 Mar 2009 22:17:35 +0000]
Mark modules upgraded today as "upstream from CPAN"
Chris 'BinGOs' Williams [Sun, 1 Mar 2009 21:27:17 +0000]
Update CPANPLUS::Dist::Build to 0.08
Rafael Garcia-Suarez [Sun, 1 Mar 2009 16:30:21 +0000]
Update to Term::ANSIColor 2.00
Craig A. Berry [Sat, 28 Feb 2009 17:47:56 +0000]
Make deprecate.pm work on VMS.
Goro Fuji [Sat, 28 Feb 2009 10:21:38 +0000]
Hash::Util::FieldHash 1.03 leaks SVs which are used as object IDs stored in mg->mg_obj
Rafael Garcia-Suarez [Fri, 27 Feb 2009 14:29:07 +0000]
NAME section must fit on one line
Robin Barker [Wed, 25 Feb 2009 18:05:09 +0000]
rewrote deprecate test using File::Spec
Robin Barker [Thu, 26 Feb 2009 17:08:35 +0000]
add standard documentation to deprecate
Nicholas Clark [Thu, 26 Feb 2009 22:31:39 +0000]
6c0ec79a2e9c445ac9999df2 failed to build from distclean - also tweak make_ext.pl
Rafael Garcia-Suarez [Thu, 26 Feb 2009 10:00:40 +0000]
Remove spurious TODO indicators
By definition, the first test in a series for testing a
leak should always succeed
Nicholas Clark [Thu, 26 Feb 2009 08:34:36 +0000]
Correct the paths for the nonxs_ext targets, following the ext flattening.
(Static and dynamic each build a target in lib/auto, which was unchanged.
nonxs_ext use a target inside the extension's directory, which was moved, but
Makefile.SH had not been updated to reflect this.)
Nicholas Clark [Thu, 26 Feb 2009 08:16:39 +0000]
Yasuhiro Matsumoto [Thu, 26 Feb 2009 08:09:33 +0000]
Make non-blocking mode work on Windows in IO::Socket::INET
CPAN RT bug #43573
Paul Marquess [Wed, 25 Feb 2009 23:20:05 +0000]
Update Filter::Util::Call to 1.08
David Mitchell [Wed, 25 Feb 2009 22:32:37 +0000]
fix typo in pod/perlperf.pod
Craig A. Berry [Wed, 25 Feb 2009 13:43:23 +0000]
MakeMaker is first-come in Maintainers.pl.
Says Schwern in Message-ID: <
49A5290F.1060400@pobox.com>.
Robin Barker [Wed, 25 Feb 2009 08:41:52 +0000]
test script for deprecate.pm
First pass at tests for deprecate.pm.
Had to modify the module to provide an interface for testing - need to
provide fake install directories, but deprecated reads from
%Config::Config, which is read only.
Jos I. Boumans [Wed, 25 Feb 2009 08:31:02 +0000]
add-package.pl fixup
Sometimes, using find, add-package.pl will construct filenames with 2
consecutive slashes, ie:
Package-Name/bin//script.pl
As this literal string isn't in the MANIFEST yet, it'll be added
erroneously. The below patch fixes this.
Robin Barker [Tue, 24 Feb 2009 09:57:23 +0000]
remove explicit caller depth in deprecate.pm by searching caller stack for use/require Module.pm
Rafael Garcia-Suarez [Tue, 24 Feb 2009 09:21:09 +0000]
Fix line number test for scalar attribute handlers
Un-TODO the tests for bleadperl and above
Jerry D. Hedden [Mon, 23 Feb 2009 17:37:16 +0000]
Fix to installing non-xs ext's in priv lib
Jerry D. Hedden [Mon, 23 Feb 2009 19:43:46 +0000]
Upgrade to threads::shared 1.28
Jerry D. Hedden [Mon, 23 Feb 2009 20:11:01 +0000]
Upgrade to threads 1.72
Nicholas Clark [Mon, 23 Feb 2009 23:37:35 +0000]
In S_parse_body(), sv hasn't been needed since -P bit the dust.
(And probably should have been removed with change 32958,
2f3529075cdaceeaf619b8bd308885878ec9828a)
Steve Peters [Mon, 23 Feb 2009 19:57:38 +0000]
Merge branch 'blead' of ssh://stevep@perl5.git.perl.org/gitroot/perl into blead
Steve Peters [Mon, 23 Feb 2009 19:25:33 +0000]
fileno() was failing when passed a NULL. I'm guessing that we don't really need to increase the refcount on a NULL fd.
Jerry D. Hedden [Mon, 23 Feb 2009 16:04:07 +0000]
Fix unused variable warning
Attached patch fixes the following build warnings:
perlmini.c: In function `S_incpush':
perlmini.c:4358: warning: unused variable `addoldvers'
perl.c: In function `S_incpush':
perl.c:4358: warning: unused variable `addoldvers'
From
87b6dbeb18691177a2b2e8dc971da242ac831c03 Mon Sep 17 00:00:00 2001
From: Jerry D. Hedden <jdhedden@cpan.org>
Date: Mon, 23 Feb 2009 10:58:14 -0500
Subject: [PATCH] Fix unused variable warning
Nicholas Clark [Mon, 23 Feb 2009 14:43:09 +0000]
Re-apply
cd5cc49dbc0e5ee748252c2da8b435855908e6d2 (Module::Build on VMS, #42724)
Nicholas Clark [Mon, 23 Feb 2009 14:15:49 +0000]
Update to Module::Build 0.31_04 (with a tweak to MBTest.pm)
Nicholas Clark [Mon, 23 Feb 2009 13:23:30 +0000]
Nicholas Clark [Mon, 23 Feb 2009 12:29:31 +0000]
Module::Build Changes from 0.31012, which hadn't been updated.
Nicholas Clark [Mon, 23 Feb 2009 10:27:08 +0000]
Add deprecate.pm. Deprecate shipping Switch.pm in the core distribution.
John Malmberg [Sun, 22 Feb 2009 18:23:29 +0000]
vms.c - Remove .DIR; in UNIX mode.
When doing a readdir() or glob() with DECC$FILENAME_UNIX_REPORT active,
the ".DIR" suffix needs to be removed for directories.
Craig A. Berry [Mon, 23 Feb 2009 03:14:17 +0000]
VMS-specific nit in S_init_perllib after
2cace6acdfad87b2d298bff18b91b339c18fd1e3.
Craig A. Berry [Mon, 23 Feb 2009 00:28:13 +0000]
time_t is unsigned 32-bit on VMS; pick sGMTIME_max and sLOCALTIME_max accordingly.
Nicholas Clark [Sun, 22 Feb 2009 22:17:47 +0000]
For S_incpush(), dir is never NULL, and len is always > 0.
Nicholas Clark [Sun, 22 Feb 2009 21:27:18 +0000]
Optimise S_incpush() by avoiding repeatedly copying libdir to subdir.
Specifically, copy it once with newSVsv(), then pass libdir to
S_incpush_if_exists(), and if that creates a new SV, use newSVsv() there to
re-do the copy. Otherwise reset the length of the passed-in SV (which is
subdir), back to the length of libdir, effectively truncating it back to be
equal to libdir. This avoids repeated copying of the same bytes over the same
memory that already holds those bytes.
Nicholas Clark [Sun, 22 Feb 2009 21:11:19 +0000]
In S_incpush, move the declaration of subdir inside the only block that uses it.
Nicholas Clark [Sun, 22 Feb 2009 21:00:03 +0000]
Tidy up incpush. Re-order the macros, and re-indent some code.
Nicholas Clark [Sun, 22 Feb 2009 20:45:04 +0000]
Move unversioned directories in PERL_OTHERLIBDIRS later in @INC.
Split INCPUSH_ADD_SUB_DIRS into INCPUSH_ADD_VERSIONED_SUB_DIRS and
INCPUSH_ADD_ARCHONLY_SUB_DIRS, and tweak the flags used for the two halves of
PERL_OTHERLIBDIRS so that .../$archname and .../ come after .../$old_version
Nicholas Clark [Sun, 22 Feb 2009 20:29:32 +0000]
Nicholas Clark [Sun, 22 Feb 2009 19:27:48 +0000]
In S_init_perllib(), push the bare VENDORLIB_STEM onto @INC after its subdirs.
Nicholas Clark [Sun, 22 Feb 2009 19:27:08 +0000]
In S_init_perllib(), push the bare SITELIB_STEM onto @INC after its subdirs.
Nicholas Clark [Sun, 22 Feb 2009 19:24:49 +0000]
In S_incpush(), move push @INC, ".../$archname" if -d ".../$archname"; later.
This effects this change:
--- Start 2009-02-21 14:04:40.
000000000 +0100
+++ /dev/fd/63 2009-02-22 16:41:18.
000000000 +0100
@@ -1,14 +1,14 @@
/Users/nick/Sandpit/511v/hashbangI/5.11.0/darwin-thread-multi-64int-2level
/Users/nick/Sandpit/511v/hashbangI/5.11.0
-/Users/nick/Sandpit/511v/hashbangI/darwin-thread-multi-64int-2level
/Users/nick/Sandpit/511v/hashbangI/5.11.-2/darwin-thread-multi-64int-2level
/Users/nick/Sandpit/511v/hashbangI/5.11.-2
+/Users/nick/Sandpit/511v/hashbangI/darwin-thread-multi-64int-2level
/Users/nick/Sandpit/511v/hashbangI
/Users/nick/Sandpit/511v/cliI/5.11.0/darwin-thread-multi-64int-2level
/Users/nick/Sandpit/511v/cliI/5.11.0
-/Users/nick/Sandpit/511v/cliI/darwin-thread-multi-64int-2level
/Users/nick/Sandpit/511v/cliI/5.11.-1/darwin-thread-multi-64int-2level
/Users/nick/Sandpit/511v/cliI/5.11.-1
+/Users/nick/Sandpit/511v/cliI/darwin-thread-multi-64int-2level
/Users/nick/Sandpit/511v/cliI
/Users/nick/Sandpit/511v/perl5lib0/5.11.0/darwin-thread-multi-64int-2level
/Users/nick/Sandpit/511v/perl5lib0/5.11.0
Nicholas Clark [Sun, 22 Feb 2009 17:37:26 +0000]
In S_init_perllib(), initialise perl5lib to NULL, to keep trace flow happy.
Nicholas Clark [Sun, 22 Feb 2009 17:24:04 +0000]
In S_incpush(), replace (addsubdirs || addoldvers) with a constant variable.
Nicholas Clark [Sun, 22 Feb 2009 13:05:38 +0000]
In S_init_perllib(), s can be const char*
Nicholas Clark [Sun, 22 Feb 2009 12:55:49 +0000]
In S_init_perllib(), only call PerlEnv_getenv("PERL5LIB") once.
Nicholas Clark [Sun, 22 Feb 2009 12:34:29 +0000]
Unwind the implicit loop in S_init_perllib(), by writing the code out longhand.
Call it only once, remove the old_vers parameter, and all the related
conditional code.
Nicholas Clark [Sat, 21 Feb 2009 17:23:46 +0000]
Change the value passed into S_init_perllib() to a boolean flag.
Nicholas Clark [Sat, 21 Feb 2009 07:06:06 +0000]
NetWare has PRIVLIB_EXP as something other than a string constant. Cope with it.
Craig A. Berry [Sat, 21 Feb 2009 20:46:27 +0000]
Use "system" gmtime in time64 on VMS so C<vmsish 'time'> pragma works.
It's not really the system gmtime; it's the homegrown one in vms/vms.c
that checks hints and does shifting between UTC and local time when
requested.
Nicholas Clark [Sat, 21 Feb 2009 18:04:08 +0000]
In S_init_perllib(), correct errors in the MACOS_TRADITIONAL conditional code.
(Errors that originated in
a26c0e281cb6068a8d148933281d8186f1eb4206 and
50d61629dc7fe34f077b9f66c50287d839e06378)
Nicholas Clark [Sat, 21 Feb 2009 08:41:14 +0000]
Re-apply changes
4adc95e616bac7ee and 200cbd6aa595a074 (RT #61492)
(ExtUtils::MM_Win32 should not generate "mt" command when CRT is statically
linked)(We'd failed to send this one upstream. Bad us.)
Nicholas Clark [Sat, 21 Feb 2009 08:11:13 +0000]
Upgrade to ExtUtils::MakeMaker 6.49_01
Craig A. Berry [Sat, 21 Feb 2009 04:58:55 +0000]
Skip time64 when there is no 64-bit integer type available.
The y2038 code currently requires that a 64-bit integer type be available,
so the build falls down hard if we try to use it where there isn't one. A
better fix might be to try NV for time_t and a 32-bit integer for year.
N.B. We test for the definedness of Quad_t rather than HAS_QUAD since the
latter is explicitly undef'd in the case where 64-bit types are available
but are not being used for Perl's IV and UV.
Craig A. Berry [Fri, 20 Feb 2009 23:43:08 +0000]
Avoid VMS long filename support on older systems that don't have it.
Craig A. Berry [Fri, 20 Feb 2009 23:37:47 +0000]
Move redefinition of lstat above its first use in vms/vms.c.
Rafael Garcia-Suarez [Fri, 20 Feb 2009 23:06:22 +0000]
More smartmatch tests
This includes a TODO for overloaded objects.
Tests will need to be augmented and better organized.
Nicholas Clark [Fri, 20 Feb 2009 20:09:16 +0000]
Add a parameter to win32_get_{priv,site,vendor}lib(), to return the length,
as we already know it, and use it in S_init_perllib() to save a strlen() in
S_incpush_use_sep().
Steffen Mueller [Fri, 20 Feb 2009 18:22:57 +0000]
Text::Wrap maintained via the CPAN release
Jerry D. Hedden [Fri, 20 Feb 2009 14:45:41 +0000]
Check for thread failure in prime number example
Rafael Garcia-Suarez [Fri, 20 Feb 2009 13:45:36 +0000]
Silence a casting warning with memchr()
Alex Davies [Fri, 20 Feb 2009 08:39:29 +0000]
Wonky example in perlthrtut
Fix at least the syntax of the example.
See : Message-ID: <
F00A81D78228413FBED223C3919BE75B@Amelie>
Leon Brocard [Fri, 20 Feb 2009 08:31:40 +0000]
Merge branch 'blead' of ssh://perl5.git.perl.org/gitroot/perl into blead
Leon Brocard [Fri, 20 Feb 2009 08:30:59 +0000]
Remove the -x from the cherry pick and show how to merge the whole branch (suggested by rgs)
Rafael Garcia-Suarez [Tue, 17 Feb 2009 12:56:43 +0000]
Reorder and complete tests for smart matching with objects
Rafael Garcia-Suarez [Tue, 17 Feb 2009 07:22:44 +0000]
Fix {%hash} ~~ %hash test
This was not parsed as a smart match, because {%hash} was taken
as a block, not a an anonymous hash.
Also, avoid to construct an anonymous hash with an odd number of
elements.
Rafael Garcia-Suarez [Tue, 17 Feb 2009 06:50:16 +0000]
Better diagnostics for the ~~ test
Read from DATA line per line, so warnings are reported from the correct
line. Make test names and error reports more readable.
Leon Brocard [Fri, 20 Feb 2009 08:25:18 +0000]
Remove an extra space
Leon Brocard [Fri, 20 Feb 2009 08:22:23 +0000]
Add a section on merging from a branch via GitHub
Dan Dascalescu [Fri, 20 Feb 2009 06:48:09 +0000]
Fixed missing word in Text::Wrap POD
(cherry picked from commit
3adac458cb1c1d41af47fc66e67b49c8dec2323f)