Karl Williamson [Thu, 26 May 2011 18:48:05 +0000 (12:48 -0600)]
podcheck.t: Add comment, explicit return
Karl Williamson [Thu, 26 May 2011 18:39:30 +0000 (12:39 -0600)]
podcheck.t: Skip broken symbolic links
This stemmed from a build issue in some smokers. The symbolic link 'U'
was left over. If another type of file can't be opened, instead of
dying, this now just fails it as one test.
Karl Williamson [Thu, 26 May 2011 18:35:42 +0000 (12:35 -0600)]
podcheck.t: Skip some more non-pod files
This skips editor droppings.
Karl Williamson [Wed, 25 May 2011 19:15:27 +0000 (13:15 -0600)]
podcheck.t: Force non-utf8 reading of files
podcheck.t was failing when PERL_UNICODE was set to empty with
a UTF-8 locale, as it tried to read things in utf8 that aren't.
This led to a fatal malformed utf8 error.
This forces the :bytes layer when reading these files.
John P. Linderman [Wed, 25 May 2011 15:36:27 +0000 (08:36 -0700)]
[perl #91614] Suggestion for improving documentation of $!
While trying to understand a bug report at
http://www.perlmonks.org/?node_id=906466
I realized that the documentation for $! was not crystal clear. For example
If used numerically, yields the current value of the
C C<errno> variable, or in other words,
if a system or library call fails, it sets this variable.
That's not "in other words", these are totally different
concepts. And it isn't clear whether this variable refers to
errno or $! (I assumed the latter, and was wrong, as Devel::Peek
demonstrated). And $! cannot be undef, as asserted (later),
because errno always contains a value, however irrelevant.
Father Chrysostomos [Wed, 25 May 2011 03:19:55 +0000 (20:19 -0700)]
podcheck.t: Skip files left by patch
Hojung Yoon [Wed, 25 May 2011 01:18:14 +0000 (18:18 -0700)]
[perl #90888] each(ARRAY) on scalar context should wrapped into defined()
"perldoc -f each" says that if each() is performed on ARRAY
in scalar context, it will return only the index in an array.
Calling each(HASH) in scalar context worked well but calling
each(ARRAY) didn't because it was not wrapped into defined OPCODE.
So, in Perl_newWHILEOP() and Perl_newLOOPOP(), they are modified
to check them and wrap with defined OP if needed.
In S_new_logop(), it's reasonable to warn if return value of
each(ARRAY) is being used for boolean value, as it's first return
value will be "0", the false.
issue: #90888
link: http://rt.perl.org/rt3/Public/Bug/Display.html?id=90888
Father Chrysostomos [Wed, 25 May 2011 01:17:45 +0000 (18:17 -0700)]
Add Hojung Yoon to AUTHORS
Nicholas Clark [Tue, 24 May 2011 20:37:26 +0000 (21:37 +0100)]
In Perl_pv_escape(), avoid reading 1 byte beyond the end of the buffer.
The check for whether to use 3 digits of octal was not correct, and was capable
of reading the byte beyond the passed in buffer. Except for the small
possibility that that byte was not mapped memory, it wouldn't change the
semantic correctness of the escaped output, but it would lead to
non-deterministic choice of which format to use.
Johan Vromans [Tue, 24 May 2011 15:35:37 +0000 (08:35 -0700)]
[perl #91518] Fix minor typo in pod/perlsub.pod.
Johan Vromans [Tue, 24 May 2011 15:34:33 +0000 (08:34 -0700)]
[perl #91508] __DATA__ starts reading on the next line
In pod/perldata it is described that the DATA filehandle starts
reading after the __DATA__ token. In reality, it starts reading on the
line following the __DATA__ token.
Example:
print while <DATA>; __DATA__ foo
bar
This prints "bar", not "foo\nbar".
The attached patch fixes the documentation in pod/perldata.pod.
Nicholas Clark [Tue, 24 May 2011 10:28:02 +0000 (11:28 +0100)]
Improve comments in sv.h describing SVrepl_EVAL and SVf_IVisUV.
Father Chrysostomos [Tue, 24 May 2011 03:18:24 +0000 (20:18 -0700)]
Un-TODO a test on Snow Leopard
Snow Leopard is Darwin 10, which compares less than 6 lexicographically.
Karl Williamson [Mon, 23 May 2011 18:33:09 +0000 (12:33 -0600)]
podcheck.t: Convert to Un*x style for file name eq
The db keeps the file names stored in Un*x style. Convert the
filenames returned by the OS into that style to get an apples
to apples comparison
Claudio Ramirez [Mon, 23 May 2011 15:33:58 +0000 (08:33 -0700)]
[perl #90850] Outdated Solaris pkg list on README.solaris
The required packages for building perl on Solaris are outdated.
The complete list is only appliable to Solaris 8 (released in
February 2000, end of support in March 2009). The patch updates
the requirements for Solaris 9 and 10 (in short: dropping
no longer existant packages).
Father Chrysostomos [Mon, 23 May 2011 15:33:48 +0000 (08:33 -0700)]
Add Claudio Ramirez to AUTHORS
Nicholas Clark [Fri, 20 May 2011 09:37:13 +0000 (10:37 +0100)]
Restore cmpVERSION.pl's ability to spot differences in XS files.
Since the refactor to use git tags (instead of a second source tree),
cmpVERSION.pl was only spotting differences in XS files if the corresponding
PM file was also modified. If only the XS file was modified, this was going
undetected.
Remove compare_git_file() - if git has already told us that a file differs,
there's no need to duplicate the work of comparison in Perl.
Nicholas Clark [Thu, 19 May 2011 19:24:14 +0000 (20:24 +0100)]
Fold Abigail's TAP generation logic back into cmpVERSION.pl
Reduce t/porting/cmp_version.t down to an invocation of cmpVERSION.pl with
--tap.
Nicholas Clark [Thu, 19 May 2011 17:25:36 +0000 (18:25 +0100)]
Change the -x option of cmpVERSION.pl to exclude upstream ne 'blead'
Previously it was excluding if CPAN were true, which meant that anything
with a DISTRIBUTION was excluded, including files where blead is upstream,
and hence something we should fix.
Nicholas Clark [Thu, 19 May 2011 17:00:37 +0000 (18:00 +0100)]
Pass the git tag to cmpVERSION.pl with a --tag argument.
If no tag is specified, default to git describe --abbrev=0.
(This is David Golden's suggestion, added t/porting/cmp_version.t in
3d92e8b1e4996571)
Eliminate the source_dir command line argument - this is now always assumed to
be '.'.
Nicholas Clark [Thu, 19 May 2011 16:22:43 +0000 (17:22 +0100)]
Convert cmpVERSION.pl to Getopt::Long from Getopt::Std.
Nicholas Clark [Thu, 19 May 2011 15:55:06 +0000 (16:55 +0100)]
Trim the import list from File::Spec::Functions and don't use File::Find.
Most of the vestigial entries were caused by the refactoring to use git in
42e700c91cf83f56. Use File::Spec::Functions::devnull() in place of hard coded
values based on $^O.
Nicholas Clark [Thu, 19 May 2011 15:39:50 +0000 (16:39 +0100)]
Only load Maintainers.pm if cmpVERSION.pl is invoked with -x
Skip chdir $source_dir with -x, because -x checks that it's '.'
Nicholas Clark [Mon, 23 May 2011 14:05:42 +0000 (15:05 +0100)]
Refactor podcheck.t to slurp files into scalars, instead of an array of lines.
Multiline matches in the regex engine are faster than looping and processing
in Perl space.
Johan Vromans [Mon, 23 May 2011 13:20:21 +0000 (06:20 -0700)]
Incorrect heading and index entries for (*MARK) in pod/perlre.pod
Nicholas Clark [Mon, 23 May 2011 11:10:15 +0000 (12:10 +0100)]
Correct and update the comments about FBMs in Perl_sv_2[inu]v_flags().
Nicholas Clark [Mon, 23 May 2011 09:21:07 +0000 (10:21 +0100)]
Add find2perl as a dependency for the target 'test_prep'.
If t/porting/podcheck.t can't find x2p/find2perl, then it is unable to find an
external target for a pod link in perlutil.pod, which it flags up as an error.
find2perl was already a dependency of the 'all' target, hence without this
rule podcheck.t would pass for 'make all test', but not 'make test'.
Father Chrysostomos [Mon, 23 May 2011 06:23:29 +0000 (23:23 -0700)]
Add another address for Sisyphus
Sisyphus [Mon, 23 May 2011 06:15:30 +0000 (23:15 -0700)]
[perl #91354] win32/makefile.mk needs patching for gcc-4.x.x
The current win32/makefile.mk wants us to edit it when we are using
the gcc-4.x.x compiler. Firstly, we have to signify that we are using
gcc-4.x.x, then we have to nominate (from a supplied list) the name of
the helper dll that needs to be copied to the t folder (in order that
the taint.t tests can pass).
The supplied list of candidates is deficient - the name of the helper
dll from one of my gcc compilers is not listed there. Also, I'm now
finding that a second dll (libstdc++-6.dll) needs to be copied to the
t folder - otherwise the taint.t test still crashes.
The attached makefile.mk patch addresses these issues in such a way
that we don't have to do any editting (re the using of gcc-4.x.x) of
the makefile.mk at all.
There's a small discussion about this on the p5p mailing list in the
thread "win32/makefile.mk patch" (15 may 2011).
This change to the makefile.mk means that README.win32 needs a
slight modification - and the attached README.win32 patch addresses
that issue.
The README.win32 patch also alters the link to the 64-bit (mingw64)
compiler made available by kmx. This has nothing to do with the
subject of this bug report, but I don't see why that correction to
the link (as suggested to me by kmx, in private correspondence)
can't be made.
Max Maischein [Mon, 23 May 2011 04:36:57 +0000 (21:36 -0700)]
Turn $$ into a magical readonly variable that always fetches getpid() instead of caching it
The intent is that by not caching $$, we eliminate one opportunity for bugs:
If one embeds Perl or uses XS and calls fork(3) from C, Perls notion of $$
may go out of sync with what getpid() returns. By always fetching the
value of $$ via getpid(), this bug opportunity is eliminated. The overhead
of always fetching $$ should be small and is likely only used for tempfile
creation, which should be dwarfed by file system accesses.
Father Chrysostomos [Mon, 23 May 2011 01:23:49 +0000 (18:23 -0700)]
Make hash-rt85026.t less noisy
Karl Williamson [Mon, 23 May 2011 03:21:31 +0000 (21:21 -0600)]
podcheck.t: Extract line numbers from strings properly
There was a typo in this regex. I added a \b for good measure.
This bug was currently showing up on VMS-only, where a string
was getting returned instead of a hash. And the regex that
deals with strings had a typo, so wasn't matching.
It remains to be seen if there is an underlying issue on VMS that
was causing this error, and other OSs don't have it.
Karl Williamson [Mon, 23 May 2011 02:26:47 +0000 (20:26 -0600)]
podcheck.t: Skip perltoc
This pod is extracted from other pods, and the possible errors in those
extractions just keep propagating to this pod. I tried to fix this
by having -1 entries in perltoc for the common errors which means
to not output them. But new ones keep cropping up. So, reluctantly,
I think it's best to just not process this file.
Nicholas Clark [Thu, 28 Apr 2011 14:14:03 +0000 (15:14 +0100)]
Perl_refcounted_he_inc() needs a dVAR to compile with -DPERL_GLOBAL_STRUCT
Nicholas Clark [Thu, 28 Apr 2011 13:36:15 +0000 (14:36 +0100)]
Restore building with -DPERL_GLOBAL_STRUCT, broken since
4dc941f7cb795735.
As PL_charclass is a constant, it doesn't need to be accessed via the global
struct. It should be exported via globvar.sym, not PERLVARA() in perlvars.h
[With a PERVARA() it all compiles perfectly, once C<dVAR>s are added where
now needed, but the build loops forever because the (real) charclass array is
never initialised]
Josh Jore [Sun, 22 May 2011 19:25:26 +0000 (12:25 -0700)]
Downgrade Unicode pod escape to ASCII for readbility
Karl Williamson [Sun, 22 May 2011 16:51:40 +0000 (10:51 -0600)]
regcomp.c: Another leak regression
Father Chrysostomos [Sun, 22 May 2011 01:38:46 +0000 (18:38 -0700)]
Fix deparsing of subs named :::: and ::::::
Since a name like :::: is now divided up as ::/:: (since commit
088225f), there can be a package called ‘::’. But %:: returns %main::,
not %main::::. The result is that the main package is searched again
and again recursively and stash_subs hangs.
The easiest fix is to put main:: at the beginning of a substash’s name
when fetching the stash.
Father Chrysostomos [Sat, 21 May 2011 17:18:26 +0000 (10:18 -0700)]
Test require override with Deparse [perl #62500]
Tom Christiansen [Sat, 21 May 2011 12:19:09 +0000 (05:19 -0700)]
General perlfunc edit; document ‘default’
Father Chrysostomos [Sat, 21 May 2011 05:08:42 +0000 (22:08 -0700)]
Revert "Revert "Missing bug number in d12b49d""
This reverts commit
d33333ec9850d2a0f2f5466e207dcc612dc4dc31.
Father Chrysostomos [Sat, 21 May 2011 05:07:50 +0000 (22:07 -0700)]
Increase constant’s version
in preparation for the next commit
Father Chrysostomos [Sat, 21 May 2011 05:06:35 +0000 (22:06 -0700)]
Move an assert
Due to my own sloppy editing, this assert ending up doing nothing,
as perl would already have crashed before reaching it.
Father Chrysostomos [Sat, 21 May 2011 03:29:46 +0000 (20:29 -0700)]
What’s wrong with me?
Father Chrysostomos [Fri, 20 May 2011 23:43:11 +0000 (16:43 -0700)]
Remove fixed bug from Deparse’s docs
Father Chrysostomos [Fri, 20 May 2011 23:40:01 +0000 (16:40 -0700)]
Make Deparse use CORE:: when necessary
Till now, Deparse has not added CORE:: to built-in keywords, even when
they are overridden by subs. Now it does.
It was simply a matter of adding a ‘keyword’ sub that looks in the
current stash to determine whether there is a possible override. And
it only does so for overridable non-infix functions. It returns the
keyword with CORE:: added to the beginning if necessary. Various
parts of the code have been modified to call this routine.
Karl Williamson [Fri, 20 May 2011 22:10:29 +0000 (16:10 -0600)]
podcheck.t: Improve VMS abilities
This should solve many of the problems encountered on VMS. It does
it by lower-casing file names before comparison.
Father Chrysostomos [Fri, 20 May 2011 21:03:41 +0000 (14:03 -0700)]
Deparse: readpipe with complex expression
readpipe was always being deparse as `...` or qx.
This commit changes it to use the already-existing pure_string routine
to determine whether it can fit in `` first.
Karl Williamson [Fri, 20 May 2011 16:54:22 +0000 (10:54 -0600)]
regcomp.c: Another memory leak regression
The reference count should be decremented upon freeing.
Father Chrysostomos [Fri, 20 May 2011 16:28:51 +0000 (09:28 -0700)]
[perl #91008] Deparse doesn't like each $ref
Steffen Mueller [Fri, 20 May 2011 15:57:50 +0000 (17:57 +0200)]
Bump Attribute::Handlers version to 0.91
... to match the CPAN version.
No functional changes.
Steffen Mueller [Fri, 20 May 2011 15:54:48 +0000 (17:54 +0200)]
Bump/upgrade Filter::Simple version to 0.87
... to match CPAN release.
No functional changes.
Steffen Mueller [Fri, 20 May 2011 14:03:07 +0000 (16:03 +0200)]
Fix skip() usage in tests
It needs to know how many tests to skip. This never failed in
blead since it's perl version dependent.
Karl Williamson [Fri, 20 May 2011 14:27:02 +0000 (08:27 -0600)]
podcheck.t: Fully qualify carp call from package
Karl Williamson [Fri, 20 May 2011 03:31:35 +0000 (21:31 -0600)]
podcheck.t: Deal properly with -1 counts
These counts are for things like perltoc which are compendiums of other
pods, and so contain any errors in those other pods, which should be
output with the offending pod and not perltoc. By setting the counts of
errors to a negative in the db, the message for perltoc is suppressed.
But a message was getting improperly output with perltoc when the
original pod got fixed.
Karl Williamson [Fri, 20 May 2011 03:10:15 +0000 (21:10 -0600)]
utf8.c: revise comment
Craig A. Berry [Fri, 20 May 2011 12:36:53 +0000 (07:36 -0500)]
Filename portability for hash-rt85026.t
File::Temp::tempdir returns a directory in native syntax. You
can't just paste a file onto that in Unix syntax and expect it
to work.
Tony Cook [Tue, 29 Mar 2011 11:15:23 +0000 (22:15 +1100)]
if List-Util is built statically, depend on $(PERL_EXE) instead of the shared library
of course, it could be that these dependencies are as redundant as the
rest.
Tony Cook [Tue, 29 Mar 2011 10:42:48 +0000 (21:42 +1100)]
remove unused dependency rule generation for Text/ParseWords
1) Text/ParseWords isn't XS, so never appears in dynamic_ext
2) there's no lib/auto/Scalar/Util.$dlext target, the file would be
lib/auto/Scalar/Util/Util.$dlext , but it's built as part of
List-Util, so there's no dependency lib/auto/Scalar/Util/Util.$dlext
anyway.
Tony Cook [Tue, 29 Mar 2011 10:32:52 +0000 (21:32 +1100)]
handle a static Cwd when generating the deps for x2p/utils
Tony Cook [Tue, 29 Mar 2011 10:04:25 +0000 (21:04 +1100)]
remove unneeded dependencies against Cwd
these were added because the build process for Encode and SDBM_File
changes directory, invalidating the original "../lib:../../lib"
PERL5LIB. With buildcustomize.pl they can change directory safely.
Nicholas Clark [Fri, 20 May 2011 11:16:57 +0000 (12:16 +0100)]
Add USE_LOCALE{,_COLLATE,_CTYPE,_NUMERIC} to the output of perl -V
These 4 compile-time options should be reported, as they have affect the
behaviour of the interpreter binary (albeit only in a small area). They don't
affect binary compatibility.
Nicholas Clark [Tue, 17 May 2011 15:07:17 +0000 (16:07 +0100)]
Correct comments about B::PV::PVBM.
Original comments, partially incorrect, added in
5a44e503dc748f53 and
f4c3658468ba5234.
Nicholas Clark [Fri, 20 May 2011 09:19:33 +0000 (10:19 +0100)]
Bump the version of PerlIO::encoding following
1c2e8ccaafb0b2b1.
1c2e8ccaafb0b2b1 fixed a typo in a comment in the XS code.
Nicholas Clark [Fri, 20 May 2011 08:49:24 +0000 (09:49 +0100)]
Bump the versions of B and Storable following
1b95d04f713d9c56.
1b95d04f713d9c56 changed HvKEYS() to HvUSEDKEYS() in the XS code.
Nicholas Clark [Fri, 20 May 2011 08:39:11 +0000 (09:39 +0100)]
Use L<> rather than C<> in the Updated Modules section of perldelta.
Previous perldeltas have been inconsistent with each other as to whether to
use L<> to C<> (but internally consistent). perldelta5140.pod uses L<>, which
is more useful, as it provides a direct link to fuller documentation at the
point where the reader is likely to want to follow it.
Switch the two existing entries from C<> to L<>, and update the perldelta
template to suggest L<>.
Father Chrysostomos [Fri, 20 May 2011 00:05:48 +0000 (17:05 -0700)]
Tests for iterator deletion [perl #85026]
Ton Hospel [Fri, 20 May 2011 00:05:16 +0000 (17:05 -0700)]
[perl #85026] Deleting the current iterator in void context
Looking at the delete code I see another strange thing. If the delete
of the current iterator is done with the G_DISCARD flag, the corres-
ponding value is not freed and survives until the lazy deleted entry
gets removed on the next hash iteration. This is easily demonstrated
like this:
perl -wle '
sub DESTROY { print "DESTROY" }
%a=(a=>bless[]);
each %a;
delete $a{a};
print "END"
'
This prints:
END
DESTROY
notice the difference with:
perl -wle '
sub DESTROY { print "DESTROY" }
%hash = (a => bless[]);
each %hash;
$dummy = delete $hash{a}; $dummy = 0;
print "END"
'
This prints:
DESTROY
END
This is easily solved by always replacing the deleted entry value with
&PL_sv_placeholder. It actually simplifies the code a bit except for the
fact that the mro_method_changed from free_hash_ent now has to be done
in hv_delete
Father Chrysostomos [Thu, 19 May 2011 23:54:01 +0000 (16:54 -0700)]
Tests for #85026
Almost all of this is taken verbatim from Ton Hospel’s sample script
for demonstrating the bug.
Ton Hospel [Mon, 16 May 2011 15:33:07 +0000 (08:33 -0700)]
[perl #85026] deleting elements in a HASH iterator
Internally a perl HASH is an array of single linked chains of entries.
Deleting an element means removing the correct chain entry by replacing
the pointer to the removed entry with a pointer to the next entry and
then freeing the deleted entry
However, if the deleted element is the current entry the deleted entry
is kept after removing it from the chain and the LAZYDEL flag is set.
Only on the next iteration is the element actually removed and the
iterator is set to the next entry.
However, if you delete the current iterator and then delete the next
element in the same chain the "next" pointer of the iterator is not
updated because the iterator is not on the chain anymore. That means
that when the next iteration looks up the iterator next pointer it
will point to the freed memory of the second element.
This patch fixes the places where the delete is done. Drawback is that
you may never forget to do the lazydel fixup in at any place where the
entry chain gets shortened.
Karl Williamson [Thu, 19 May 2011 22:39:20 +0000 (16:39 -0600)]
perlvar: Fix broken links
Karl Williamson [Thu, 19 May 2011 22:38:27 +0000 (16:38 -0600)]
perluniintro: fix broken link
Karl Williamson [Thu, 19 May 2011 22:35:59 +0000 (16:35 -0600)]
perlrecharclass: Fix broken link
Karl Williamson [Thu, 19 May 2011 22:34:27 +0000 (16:34 -0600)]
perlre: Fix broken links
Karl Williamson [Thu, 19 May 2011 22:29:11 +0000 (16:29 -0600)]
podcheck.t: Missing diagnostics
podcheck.t was not outputting a message when all occurrences of
an issue were removed, and hence the database wasn't getting
regenerated
Karl Williamson [Thu, 19 May 2011 22:18:47 +0000 (16:18 -0600)]
perlutil: Fix broken links
David Mitchell [Thu, 19 May 2011 21:00:15 +0000 (22:00 +0100)]
Maintainers.pl: fix podlators entry
The mapping didn't include the basic '' => cpan/podlators entry,
so core-cpan-diff was reporting lots of errors.
Also, there was much strangeness with *.PL files.
David Mitchell [Thu, 19 May 2011 15:21:07 +0000 (16:21 +0100)]
sv_clear: destructor may change SV type
so re-initialise the 'type' var afterwards
David Mitchell [Thu, 19 May 2011 14:51:45 +0000 (15:51 +0100)]
sv_clear only test for SvOBJECT on >= MG
micro-optimisation
Robin Barker [Sun, 15 May 2011 13:40:46 +0000 (14:40 +0100)]
use __attribute__unused__ to silence -Wunused-but-set-variable
Robin Barker [Sun, 15 May 2011 18:02:29 +0000 (19:02 +0100)]
unused variables in pp_ctl.c
Michael Witten [Mon, 16 May 2011 01:57:37 +0000 (01:57 +0000)]
Docs: perlhack: Use correct shell code and better git/shell constructs
The example commands for using `git format-patch' and `perlbug' have
been streamlined, and (most importantly) single quotes have been
replaced with double quotes for constructing the argument to `-s'.
Signed-off-by: Michael Witten <mfwitten@gmail.com>
Father Chrysostomos [Thu, 19 May 2011 17:48:37 +0000 (10:48 -0700)]
Regenerate known_pod_issues.dat
podcheck.t is producing spurious failures for two files.
Zsbán Ambrus [Thu, 19 May 2011 05:03:43 +0000 (22:03 -0700)]
[perl #90592] Porting/epigraphs.pod: add 5.14.0(-RC*)
Karl Williamson [Tue, 17 May 2011 23:28:51 +0000 (17:28 -0600)]
regcomp.c: Fix bug in inversion list intersection
This code was derived from published code, which says use at your
own risk. And in fact had bugs. I don't believe these show up in
5.14, as I think you have to have a list that has been inverted for this
to happen.
The comments describe what should have been done.
Karl Williamson [Tue, 17 May 2011 23:25:22 +0000 (17:25 -0600)]
regcomp.c: Add new macro for readability
Adding this macro which is the complement of an existing macro helps
understanding what is happening at its point of use
Karl Williamson [Sat, 14 May 2011 17:43:05 +0000 (11:43 -0600)]
perluniprops: Add markup, like C<>
Karl Williamson [Fri, 13 May 2011 16:44:06 +0000 (10:44 -0600)]
fold_grind.t: Revamp test case coverage analysis
The kludgy analysis of what tests to do is hereby simplified and
improved, finding a few extra bugs.
Karl Williamson [Fri, 13 May 2011 16:30:39 +0000 (10:30 -0600)]
regcomp.c: Greek multi-char folds fix
GREEK PROSGEGRAMMENI and COMBINING GREEK YPOGEGRAMMENI fold to the
the first character of one of the tricky folds, and hence need
to be treated as potentially tricky themselves.
Karl Williamson [Fri, 13 May 2011 16:25:16 +0000 (10:25 -0600)]
regcomp.c: \x{17f} can match /\xdf/i
Karl Williamson [Fri, 13 May 2011 16:22:16 +0000 (10:22 -0600)]
fold_grind.t: remove unnecessary tests
This is supposed to test weird combinations of things. Tests like
'ss' =~ /SS/i
aren't weird, and so can be skipped.
Karl Williamson [Fri, 13 May 2011 16:02:18 +0000 (10:02 -0600)]
fold_grind.t: No longer any TODOs
Karl Williamson [Thu, 12 May 2011 03:39:19 +0000 (21:39 -0600)]
Fix some multi-char /i fold bugs
Consider U+FB05 and U+FB06. These both fold to 'st', and hence should
match each other under /i. However, Unicode doesn't furnish a rule for
this, and Perl hasn't been smart enought to figure it out. The bug that
shows up is in constructs like
"\x{fb06}" =~ /[^\x{fb05}]/i
succeeding. Most of these instances also have a 'S' entry in Unicode's
CaseFolding.txt, which avoids the problem (as mktables was earlier
changed to include those in the generated table). But there were
several code points that didn't.
This patch changes utf8.c to look for these when constructing it's
inverted list of case fold equivalents. An alternative would have been
to change mktables instead to look for them and create synthetic rules.
But, this is more general in case the function ends up being used for
other things.
I will change fold_grind.t to test for these in a separate commit.
Karl Williamson [Thu, 12 May 2011 03:13:30 +0000 (21:13 -0600)]
utf8.c: Remove soon-to-be-obsoleted comment
This comment will no longer apply, as the code it talked about is
moving into swash_init().
Karl Williamson [Sat, 14 May 2011 16:10:21 +0000 (10:10 -0600)]
utf8_heavy: Return pointer to special treatment hash.
Many of the mapping tables that utf8_heavy.pl deals with have maps that
don't fit into the general scheme of things, and a hash is generated for
those. This patch causes utf8_heavy to add an entry to the object it
generates containing a reference to this hash. Prior to this, the name
of the hash had to be known to the users of the table.
Karl Williamson [Sat, 14 May 2011 16:07:37 +0000 (10:07 -0600)]
utf8_heavy: Add comments
Karl Williamson [Thu, 12 May 2011 03:08:36 +0000 (21:08 -0600)]
mktables: Add info giving specials hash name
mktables creates %utf8::SwashInfo in each table it generates, giving
some info about the table. Add an entry to this for tables that have
a hash of special mappings, giving the name of that hash.
Karl Williamson [Thu, 12 May 2011 03:07:37 +0000 (21:07 -0600)]
utf8_heavy.pl: Revise comment
Karl Williamson [Wed, 11 May 2011 17:43:16 +0000 (11:43 -0600)]
utf8.c: Remove unnecessary temporary
Karl Williamson [Wed, 11 May 2011 17:38:15 +0000 (11:38 -0600)]
utf8.c: "<" should be "<="
av_len() is misnamed, and hence led me earlier to stop the loop
one shy of what it should have been. No actual bugs were caused by
this, but it could cause a duplicate entry in an array, which is
searched linearly, hence a slight slowdown.