| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
|
|
| |
This is in response to ticket [perl #118667]. This commit removes the
confusing table of equivalent Unicode properties. It contained material
about Unicode without adequate explanation beyond what a tutorial reader
would be expected to know, so I just pulled it out. The POSIX classes
haven't been introduced at this point, which really are needed for
understanding this. Below, where they are introduced, I believe the
examples make things adequately clear.
|
|
|
|
|
|
|
| |
This pod was calling bracketed character classes as just plain
"character classes", but in one place it referred to the period as a
character class as well, which is the terminology used elsewhere. This
commit notes the distinction.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
COW was first introduced (and enabled by default) in 5.17.7.
It was disabled by default in 5.17.10, because it was though to have too
many rough edges for the 5.18.0 release.
By re-enabling it now, early in the 5.19.x release cycle, hopefully it
will be ready for production use by 5.20.
This commit mainly reverts 9f351b45f4 and e1fd41328c (with modifications),
then updates perldelta.
|
|
|
|
|
|
|
|
| |
This reverts commit d78f32f607952d58a998c5b7554572320dc57b2a.
Since COW has now not been enabled by default for 5.18, revert the
documentation changes which say that that $' etc no longer have a
performance penalty, etc.
|
|
|
|
| |
plus a couple of other pod tweaks.
|
| |
|
|
|
|
|
|
| |
Update the docs and add perldelta entries summarising the changes and
fixes related to (?{}) and (??{}) accumulated over the 120 or so commits
in this branch.
|
|
|
|
| |
As noticed by Lawrence Statton <lawrence@cluon.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This autoloads charnames.pm when needed. It uses the :full and :short
options. :loose is not used because of its relative unfamiliarity in
the Perl community, and is slower. (If someone later added a typical
"use charnames qw(:full)", things that previously matched under :loose
would start to fail, causing confustion. If :loose does become more
common, we can change this in the future to use it; the converse isn't
true.)
The callable functions in the module are not automatically loaded. To
access them, an explicity "use charnames" must be provided.
Thanks to Tony Cook for doing a code inspection and finding a missing
SPAGAIN.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
These modifiers are automatically selected when various
pragmas are in effect, and their explicit use is rarely called
for, so shouldn't be mentioned in a tutorial introduction.
|
| |
|
| |
|
|
|
|
|
| |
perlretut still says /o is needed to prevent regex re-compilation in
loops.
|
|
|
|
|
|
|
| |
blocks are mostly useless, and not suitable for an introduction
to regular expressions. It was not always the case, as in very early
Unicode these were the best approximation to the much more useful
Script concept. But that changed 10 or so years ago.
|
| |
|
| |
|
|
|
|
| |
Use the link to Unicode that gives the latest version, whatever it might be
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
Since e4ed29fb stopped installing NamesList.txt the documentation can no longer
suggest use of it, instead reference the Unicode standard in use by this
version of perl.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Mostly minor punctuation changes, but also:
• Some of the ‘new’ features are no longer new.
• Explain that \Q\L\U only apply to literal regexps, not interpolated
ones.
• The charnames pragma is not required for \p
• The section on [:POSIX:] char classes was still explaining 5.6.
|
|
|
|
|
|
|
|
|
|
|
| |
In particular:
• The word ‘substitute’ was misused. I changed it to substitution,
but then realised that it was actually wordy and redundant, so I
removed it.
• The /e modifier does not do an eval{...} or eval '...' or anything
of the sort. s/foo/die/e demonstrates this clearly. (/ee is a diffe-
rent matter, but is not covered in perlretut.)
|
| |
|
|
|
|
| |
In particular, remove the obsolete mention of new features ‘in 5.6.0’.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Change the example split output in a "Non-capturing groupings" example
from ('12','a','34','b','5') to ('12','a','34','a','5'). This way
it'll match the example code that goes along with it:
split /(a|b)+/, "12aba34ba5"
Reported-by: Antonio Bonifati <antonio.bonifati@gmail.com>
|
|
|
|
|
|
|
|
|
|
| |
This commit adds the new construct \o{} to express a character constant
by its octal ordinal value, along with ancillary tests and
documentation.
A function to handle this is added to util.c, and it is called from the
3 parsing places it could occur. The function is a candidate for
in-lining, though I doubt that it will ever be used frequently.
|
|
|
|
|
|
|
| |
\g was added to avoid ambiguities that \digit causes. This updates the
pod documentation to use \g in examples, and to prefer it when
explaining the concepts. Some non-symmetrical outlined text dealing
with it was also cleaned up.
|
|
|
|
|
|
| |
Both terms 'capture group' and 'capture buffer' are used in the
documentation. This patch changes most uses of the latter to the
former, as they are referenced using "\g".
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This changes s/// so that it doesn't act destructively on its target.
Instead it returns the result of the substitution (or the original string if
there was no match).
In addition this patch:
* Adds a new warning when s///r happens in void context.
* Adds a error when you try to use s///r with !~
* Makes it so constant strings can be bound to s///r with =~
* Adds documentation.
* Adds some tests.
* Updates various debug code so it knows about the /r flag.
* Adds some new 'r' words to B::Deparse.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
I looked at all the instances of spaces around -- and in most cases
converted the sentences to use more appropriate punctuation. In
general, the -- in the perl docs seem to be there only to make
really complicated and really long sentences.
I didn't look at the closed em-dashes. They probably have the same
sentence-complexity problem.
I left some open em-dashes in place. Those are the ones used in
lists.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
These are all in the pod/ directory, and only the first is a code fix.
There was also a single lingering ISO 8859-1 encoding that missed the
UTF-8 upconvert. The rest are cleanups for typos, some of which seem
to have been around for a rather long time: spelling errors, incorrect
possessives, and extra, missing, or duplicated words.
If you actually read through, I bet you'll realize what sparked this. :)
--tom
Signed-off-by: Abigail <abigail@abigail.be>
|
|
|
|
| |
Signed-off-by: Abigail <abigail@abigail.be>
|
|
|
|
|
|
| |
in a regular expression" documentation
The docs were now wrong, due to new optimisations to the regexp engine.
|
|
|
|
| |
Thanks to "Jim Ferguson"
|
|
|
|
| |
Signed-off-by: Michael Witten <mfwitten@gmail.com>
|