summaryrefslogtreecommitdiff
path: root/lib/Pod
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2012-01-23 23:16:56 +0100
committerNicholas Clark <nick@ccl4.org>2012-02-18 13:16:51 +0100
commit9e5f1ef1bff730b36ea82e6398352eab5a575b38 (patch)
treecddb402d77c48ba5422f3f6b81b48f762b802aae /lib/Pod
parent8d9a42761c02030eee049d59f4bb4539b6955149 (diff)
downloadperl-9e5f1ef1bff730b36ea82e6398352eab5a575b38.tar.gz
Add all missing functions to Pod::Functions.
evalbytes was added to perlfunc.pod by commit 7289c5e6ca773d7c in Nov 2011. fc was added to perlfunc.pod by commit 628253b8ba8b9cbe in Jan 2012. say was added by commit 0d863452f5cac863 in Dec 2005. state was added.pod by commit 36fb85f3330d45ee in Jul 2006. __FILE__, __LINE__ and __PACKAGE__ were added by commit cfa52385fa426b5e in Aug 2011, and __SUB__ by commit 84ed01088568ffe9 in Nov 2011. Again, tweak the golden results in the test to match these changes.
Diffstat (limited to 'lib/Pod')
-rw-r--r--lib/Pod/Functions.pm16
-rw-r--r--lib/Pod/t/Functions.t19
2 files changed, 22 insertions, 13 deletions
diff --git a/lib/Pod/Functions.pm b/lib/Pod/Functions.pm
index 3712203311..6c3cb8211c 100644
--- a/lib/Pod/Functions.pm
+++ b/lib/Pod/Functions.pm
@@ -155,6 +155,7 @@ atan2 Math arctangent of Y/X in the range -PI to PI
bind Socket binds an address to a socket
binmode I/O prepare binary files for I/O
bless Objects create an object
+break Switch Break out of a C<given()> block
caller Flow,Namespace get context of the current subroutine call
chdir File change your current working directory
chmod File changes the permissions on a list of files
@@ -171,6 +172,7 @@ cos Math cosine function
crypt String one-way passwd-style encryption
dbmclose Objects,I/O breaks binding on a tied dbm file
dbmopen Objects,I/O create binding on a tied dbm file
+default Switch XXX RT #108848
defined Misc test whether a value, variable, or function is defined
delete HASH deletes a value from a hash
die I/O,Flow raise an exception or bail out
@@ -185,11 +187,14 @@ endpwent User be done using passwd file
endservent Network be done using services file
eof I/O test a filehandle for its end
eval Flow,Misc catch exceptions or compile and run code
+evalbytes Flow,Misc similar to string eval, but intend to parse a bytestream
exec Process abandon this program to run another
exists HASH test whether a hash key is present
exit Flow terminate this program
exp Math raise I<e> to a power
+fc String return casefolded version of a string
fcntl File file control system call
+__FILE__ Flow the name of the current source file
fileno I/O return file descriptor from filehandle
flock I/O lock an entire file with an advisory lock
fork Process create a new process just like this one
@@ -221,6 +226,7 @@ getservbyport Network get services record given numeric port
getservent Network get next services record
getsockname Socket retrieve the sockaddr for a given socket
getsockopt Socket get socket options on a given socket
+given Switch XXX RT #108848
glob File expand filenames using wildcards
gmtime Time convert UNIX time into record or string using Greenwich time
goto Flow create spaghetti code
@@ -237,6 +243,7 @@ last Flow exit a block prematurely
lc String return lower-case version of a string
lcfirst String return a string with just the next letter in lower case
length String return the number of bytes in a string
+__LINE__ Flow the current source line number
link File create a hard link in the filesystem
listen Socket register your socket as a server
local Misc,Namespace create a temporary value for a global variable (dynamic scoping)
@@ -255,6 +262,7 @@ my Misc,Namespace declare and assign a local variable (lexical scoping)
next Flow iterate a block prematurely
no Modules unimport some module symbols or semantics at compile time
package Modules,Objects,Namespace declare a separate global namespace
+__PACKAGE__ Flow the current package
prototype Flow,Misc get the prototype (if any) of a subroutine
oct String,Math convert a string to an octal number
open File open a file, pipe, or descriptor
@@ -292,6 +300,7 @@ rewinddir I/O reset directory handle
rindex String right-to-left substring search
rmdir File remove a directory
s/// Regexp replace a pattern with a string
+say I/O output a list to a filehandle, appending a newline
scalar Misc force a scalar context
seek I/O reposition file pointer for random-access I/O
seekdir I/O reposition directory pointer
@@ -326,8 +335,10 @@ sprintf String formatted print into a string
sqrt Math square root function
srand Math seed the random number generator
stat File get a file's status information
+state Misc,Namespace declare and assign a persistent lexical variable
study Regexp optimize input data for repeated searches
sub Flow declare a subroutine, possibly anonymously
+__SUB__ Flow the current subroutine, or C<undef> if not in a subroutine
substr String get or alter a portion of a string
symlink File create a symbolic link to a file
syscall I/O,Binary execute an arbitrary system call
@@ -360,9 +371,6 @@ wait Process wait for any child process to die
waitpid Process wait for a particular child process to die
wantarray Misc,Flow get void vs scalar vs list context of current subroutine call
warn I/O print debugging info
+when Switch XXX RT #108848
write I/O print a picture record
y/// String transliterate a string
-break Switch Break out of a C<given()> block
-default Switch XXX RT #108848
-given Switch XXX RT #108848
-when Switch XXX RT #108848
diff --git a/lib/Pod/t/Functions.t b/lib/Pod/t/Functions.t
index b874a893d9..f0c74a3589 100644
--- a/lib/Pod/t/Functions.t
+++ b/lib/Pod/t/Functions.t
@@ -75,9 +75,9 @@ Functions.t - Test Pod::Functions
__DATA__
Functions for SCALARs or strings:
- chomp, chop, chr, crypt, hex, index, lc, lcfirst, length,
- oct, ord, pack, q/STRING/, qq/STRING/, reverse, rindex,
- sprintf, substr, tr///, uc, ucfirst, y///
+ chomp, chop, chr, crypt, fc, hex, index, lc, lcfirst,
+ length, oct, ord, pack, q/STRING/, qq/STRING/, reverse,
+ rindex, sprintf, substr, tr///, uc, ucfirst, y///
Regular expressions and pattern matching:
m//, pos, qr/STRING/, quotemeta, s///, split, study
@@ -98,7 +98,7 @@ Functions for real %HASHes:
Input and output functions:
binmode, close, closedir, dbmclose, dbmopen, die, eof,
fileno, flock, format, getc, print, printf, read, readdir,
- readline, rewinddir, seek, seekdir, select, syscall,
+ readline, rewinddir, say, seek, seekdir, select, syscall,
sysread, sysseek, syswrite, tell, telldir, truncate, warn,
write
@@ -112,18 +112,19 @@ Functions for filehandles, files, or directories:
stat, symlink, sysopen, umask, unlink, utime
Keywords related to the control flow of your Perl program:
- caller, continue, die, do, dump, eval, exit, goto, last,
- next, prototype, redo, return, sub, wantarray
+ __FILE__, __LINE__, __PACKAGE__, __SUB__, caller,
+ continue, die, do, dump, eval, evalbytes, exit, goto,
+ last, next, prototype, redo, return, sub, wantarray
Keywords related to the switch feature:
break, continue, default, given, when
Keywords related to scoping:
- caller, import, local, my, our, package, use
+ caller, import, local, my, our, package, state, use
Miscellaneous functions:
- defined, dump, eval, formline, local, lock, my, our,
- prototype, reset, scalar, undef, wantarray
+ defined, dump, eval, evalbytes, formline, local, lock, my,
+ our, prototype, reset, scalar, state, undef, wantarray
Functions for processes and process groups:
alarm, exec, fork, getpgrp, getppid, getpriority, kill,