| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
| |
For some reason the argument to require v5.6 has the NOK flag on,
but the parenthesized version lacks that flag, so the code added in
v5.21.3-504-ged6f447 to precompute the hash was wrong, and caused
require(v5.6) to lose its vstringness.
|
| |
|
|
|
|
|
|
|
|
| |
I enable PERL_DISABLE_PMC in a .h, not in CCFLAGS. CCFLAGS on Unix
typically has no -Ds in it, build options go into config.h, not
Config.pm's CCFLAGS. This change allows PERL_DISABLE_PMC option to pass
tests regardless of where it is defined. cpan/parent/t/parent-pmc.t is not
fixed by this patch.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
While minitest passes all its tests when everything has been
built, it is sometimes useful to run it when nothing has been
built but miniperl (especially when one is working on low-level
stuff that breaks miniperl). Many tests fail if things have
not been built yet because miniperl can’t find modules like
re.pm. This patch fixes up some tests to find those modules
and changes _charnames.pm to load File::Spec only when it
needs it.
There are still many more failures, but I’ll leave the rest
for another time (or another hacker :-).
|
|
|
|
|
|
|
|
| |
When require is checking against a particular entry in @INC, it stats the
potential pathname, and does various checks like skipping if it's a
directory. In this case the stat succeeds, so $! is left unchanged.
Later however, pp_require() checks for $! being EACCES. So if $! was
already set before the require, this could influence require's behaviour.
|
| |
|
|
|
|
|
|
|
|
|
| |
There are random smoke failures in this test script, which are consistent
with multiple processes running the same test script in parallel, and
writing/unlinking the same (hard-coded) temp files.
As a temp hack, add a sleep(20) if this looks like its happening,
and see if the smoke issues go away.
|
|
|
|
|
|
| |
This is particularly important as in several places, the ok or not ok
message is generated in different ways depending on whether a require
successfully executed and printed "ok" for example.
|
|
|
|
|
| |
This is something I broke in my first (unapplied) attempt to clean up
require’s parsing madness.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
It doesn’t any more.
Now the hints are localised in a separate inner scope surrounding the
call to yyparse. This meant moving hint-handling code from pp_require
and pp_entereval into S_doeval.
Some tests in t/comp/hints.t were testing for the buggy behaviour, so
they have been adjusted.
Basically, this fixes
sub import {
eval "strict->import"
}
which should work the same way as
sub import {
strict->import
}
but was not working because %^H and $^H were being localised to
the eval at its run time, not just its compilation. So the values
assigned to %^H and $^H at the eval’s run time would simply be lost.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
As of commit 282b29ee485, pp_requires passes an SV to S_doopen_pm,
instead of char*/length pair.
That commit also used sv_mortalcopy() to copy the sv when trying out a
.pmc extension:
+ SV *const pmcsv = sv_mortalcopy(name);
When the path is absolute, the sv passed to S_doopen_pm is the very sv
that was passed to require. If it was returned from a (non-lvalue)
sub-routine, it will be marked TEMP, so the buffer gets stolen.
After the .pmc file is discovered to be nonexistent, S_doopen_pm then
uses its original sv to open the .pm file. But the buffer has been
stolen, so it’s trying to open undef, which fais.
In the mean time, pp_require still has a pointer to the stolen buffer,
which now has a .pmc extenion, it blithely reports that the .pmc file
cannot be found, not realising that its string has changed out from
under it. (Actually, if the file name were just the right length, it
could be reallocated and we could end up with a crash.)
This patch copies the sv more kindly.
|
|
|
|
|
|
| |
Previously in a BEGIN block, require was behaving identically to use 5.12.0 -
ie erroneously executing the use feature ':5.12.0'; and use strict;
use warnings behaviour, which only use was documented to provide.
|
| |
|
|
|
|
| |
become void context. Fixes problem with require not always being in scalar context.
|
| |
|
| |
|
| |
|
|
|
|
|
| |
Remove the direct code for testing UTF-8, calling bytes_to_utf() from a loop for
all 3 tested encodings.
|
| |
|
|
|
|
|
|
| |
The relevant line, with comment, is:
my @a; # magic guard for scope violations (must be first lexical in file)
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
| |
An errored attribute sub still processes the attributes,
which require's attribute.pm, so make sure the error state is
passed to the new require
p4raw-id: //depot/perl@33265
|
|
|
| |
p4raw-id: //depot/perl@32084
|
|
|
|
|
| |
So need to propagate errors with $@.
p4raw-id: //depot/perl@29723
|
|
|
|
|
|
|
|
|
| |
die as soon as it finds one. It should for instance be possible to
for require "File" to read the file "./File" even if there happens to
be a "File" directory in perl's standard library.
This fixes the RT #24404 fix in change 26373.
p4raw-id: //depot/perl@27515
|
|
|
| |
p4raw-id: //depot/perl@26892
|
|
|
| |
p4raw-id: //depot/perl@26891
|
|
|
|
|
| |
p4raw-link: @26881 on //depot/perl: ae706db49f17350f7e2ed5eccdc792223f4ea020
p4raw-id: //depot/perl@26883
|
|
|
|
|
| |
better to subtract the number of tests that don't get run.
p4raw-id: //depot/perl@26691
|
|
|
|
|
| |
add "new" tests before the end.
p4raw-id: //depot/perl@26377
|
|
|
|
|
| |
p4raw-link: @26373 on //depot/perl: ce8abf5f5d2e5b19646ab17c24a3ea87c70428c8
p4raw-id: //depot/perl@26375
|
|
|
|
|
| |
Message-ID: <42A414DD.8090504@rowman.com>
p4raw-id: //depot/perl@24823
|
|
|
|
|
| |
(See discussion for bug [perl #31924])
p4raw-id: //depot/perl@23873
|
|
|
|
|
| |
Message-ID: <20041013164018.GA32174@biff.bort.ca>
p4raw-id: //depot/perl@23843
|
|
|
|
|
| |
Message-ID: <411048BD.3080700@rowman.com>
p4raw-id: //depot/perl@23190
|
|
|
|
|
| |
Message-Id: <20031008224155.A14638@biff.bort.ca>
p4raw-id: //depot/perl@21427
|
|
|
|
|
| |
Message-ID: <20030923121452.G18845@biff.bort.ca>
p4raw-id: //depot/perl@21415
|
|
|
| |
p4raw-id: //depot/perl@19869
|
|
|
|
|
|
| |
require() should always be called in scalar context,
even when it's the last statement in an eval("").
p4raw-id: //depot/perl@19851
|
|
|
|
|
|
|
|
|
|
|
| |
The test for #21742 is marked as TODO.
Plus new regression tests from :
Subject: [perl #22708] void context in string eval is broken
From: "Marcus Holland-Moritz" (via RT) <perlbug-followup@perl.org>
Message-ID: <rt-22708-59432.14.6755501393177@rt.perl.org>
p4raw-link: @19126 on //depot/perl: a89be09a10c36299e755a956d356eb7f1f643437
p4raw-id: //depot/perl@19801
|
|
|
|
|
|
|
|
|
| |
scalar context. This wasn't the case when called from
an eval(""), because the void context doesn't propagate
through the leaveeval op. Instead of making scalarvoid()
handle OP_LEAVEEVAL -- this breaks AutoLoader -- implement
a workaround in doeval().
p4raw-id: //depot/perl@19126
|
|
|
| |
p4raw-id: //depot/perl@15584
|
|
|
|
|
|
|
| |
Message-ID: <m33d1tvjuq.fsf@anima.de>
(except for the three DB_File patch fragments)
p4raw-id: //depot/perl@13940
|
|
|
|
|
|
|
|
|
|
|
| |
the unnecessary "use bytes" ones.
TODO: scour the documentation for unnecessary "use utf8"
and prominently display it in perldelta when the time comes.
("use utf8" should be necessary ONLY if one wants the script
to be in UTF-8.) Also should be checked in some non-ASCII
non-Latin-1 platform, like EBCDIC.
p4raw-id: //depot/perl@11638
|
|
|
|
|
| |
Message-ID: <Pine.OSF.4.10.10103291731150.1326-100000@aspara.forte.com>
p4raw-id: //depot/perl@9461
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(sysread, recv and write i.e. formats still to do...)
Allow :utf8 or :bytes in PerlIO_apply_layers() so that
open($fh,">:utf8","name")
etc. work. - "applying" those just sets/clears the UTF8 bit of the top layer,
so no extra overhead is involved.
Tweak t/comp/require.t to add a 'use bytes' to permit its dubious writing of BOM
to a non-utf8 stream.
Add initial io/utf8.t
Fix SvPVutf8() - sv_2pv() was not expecting to be called with something
that was already SvPOK() - (we just fossiked with SvUTF8 bit). Fix that
and also just use the SvPV macro in sv_2pvutf8() to avoid the issue/overhead.
p4raw-id: //depot/perlio@8054
|