From: Jarkko Hietaniemi Date: Tue, 4 Jul 2000 20:30:56 +0000 (+0000) Subject: More POSIX.pod embellishment. X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=91e449be22b6c881704a4b50617f4b645f3805ec;p=p5sagit%2Fp5-mst-13.2.git More POSIX.pod embellishment. p4raw-id: //depot/cfgperl@6311 --- diff --git a/ext/POSIX/POSIX.pod b/ext/POSIX/POSIX.pod index c13e839..9abad2a 100644 --- a/ext/POSIX/POSIX.pod +++ b/ext/POSIX/POSIX.pod @@ -244,17 +244,20 @@ Generates the path name for the controlling terminal. =item ctime -This is identical to the C function C. +This is identical to the C function C and equivalent +to C, see L and L. =item cuserid -Get the character login name of the user. +Get the login name of the owner of the current process. $name = POSIX::cuserid(); =item difftime -This is identical to the C function C. +This is identical to the C function C, for returning +the time difference (in seconds) between two times (as returned +by C), see L. =item div @@ -263,7 +266,8 @@ the modulus C<%>. =item dup -This is similar to the C function C. +This is similar to the C function C, for duplicating a file +descriptor. This uses file descriptors such as those obtained by calling C. @@ -272,7 +276,8 @@ Returns C on failure. =item dup2 -This is similar to the C function C. +This is similar to the C function C, for duplicating a file +descriptor to an another known file descriptor. This uses file descriptors such as those obtained by calling C. @@ -285,7 +290,7 @@ Returns the value of errno. $errno = POSIX::errno(); -This identical to the numerical values of the C<$!>, see L. +This identical to the numerical values of the C<$!>, see L. =item execl @@ -362,7 +367,7 @@ Use method C instead. =item fgets -Use method C instead. Similar to <>, also known +Use method C instead. Similar to EE, also known as L. =item fileno @@ -433,11 +438,11 @@ freopen() is C-specific, see L instead. Return the mantissa and exponent of a floating-point number. - ($mantissa, $exponent) = POSIX::frexp( 3.14 ); + ($mantissa, $exponent) = POSIX::frexp( 1.234e56 ); =item fscanf -fscanf() is C-specific--use <> and regular expressions instead. +fscanf() is C-specific, use EE and regular expressions instead. =item fseek @@ -471,15 +476,18 @@ see L. =item getchar -Returns one character from STDIN. +Returns one character from STDIN. Identical to Perl's C, +see L. =item getcwd Returns the name of the current working directory. +See also L. =item getegid -Returns the effective group id. +Returns the effective group identifier. Similar to Perl' s builtin +variable C<$(>, see L. =item getenv @@ -488,74 +496,89 @@ The same information is available through the C<%ENV> array. =item geteuid -Returns the effective user id. +Returns the effective user identifier. Identical to Perl's builtin C<$E> +variable, see L. =item getgid -Returns the user's real group id. +Returns the user's real group identifier. Similar to Perl's builtin +variable C<$)>, see L. =item getgrgid -This is identical to Perl's builtin C function, -see L. +This is identical to Perl's builtin C function for +returning group entries by group identifiers, see +L. =item getgrnam -This is identical to Perl's builtin C function, -see L. +This is identical to Perl's builtin C function for +returning group entries by group names, see L. =item getgroups -Returns the ids of the user's supplementary groups. +Returns the ids of the user's supplementary groups. Similar to Perl's +builtin variable C<$)>, see L. =item getlogin -This is identical to Perl's builtin C function, -see L. +This is identical to Perl's builtin C function for +returning the user name associated with the current session, see +L. =item getpgrp -This is identical to Perl's builtin C function, -see L. +This is identical to Perl's builtin C function for +returning the prcess group identifier of the current process, see +L. =item getpid -Returns the process's id. +Returns the process identifier. Identical to Perl's builtin +variable C<$$>, see L. =item getppid -This is identical to Perl's builtin C function, -see L. +This is identical to Perl's builtin C function for +returning the process identifier of the parent process of the current +process , see L. =item getpwnam -This is identical to Perl's builtin C function, -see L. +This is identical to Perl's builtin C function for +returning user entries by user names, see L. =item getpwuid -This is identical to Perl's builtin C function, -see L. +This is identical to Perl's builtin C function for +returning user entries by user identifiers, see L. =item gets -Returns one line from C, similar to <>, also known -as the C functions, see L. +Returns one line from C, similar to EE, also known +as the C function, see L. + +B: if you have C programs that still use C, be very +afraid. The C function is a source of endless grief because +it has no buffer overrun checks. It should B be used. The +C function should be preferred instead. =item getuid -Returns the user's id. +Returns the user's identifier. Identical to Perl's builtin C<$E> variable, +see L. =item gmtime -This is identical to Perl's builtin C function, +This is identical to Perl's builtin C function for +converting seconds since the epoch to a date in Greenwich Mean Time, see L. =item isalnum This is identical to the C function, except that it can apply to a single character or to a whole string. Consider using regular expressions and the -C construct instead. +C construct instead, or possibly the C construct. =item isalpha @@ -578,7 +601,7 @@ C construct instead. This is identical to the C function, except that it can apply to a single character or to a whole string. Consider using regular expressions and the -C construct instead. +C construct instead, or the C construct. =item isgraph @@ -590,7 +613,7 @@ C construct instead. This is identical to the C function, except that it can apply to a single character or to a whole string. Consider using regular expressions and the -C construct instead. +C construct instead. Do B use C. =item isprint @@ -608,39 +631,46 @@ C construct instead. This is identical to the C function, except that it can apply to a single character or to a whole string. Consider using regular expressions and the -C construct instead. +C construct instead, or the C construct. =item isupper This is identical to the C function, except that it can apply to a single character or to a whole string. Consider using regular expressions and the -C construct instead. +C construct instead. Do B use C. =item isxdigit This is identical to the C function, except that it can apply to a single character or to a whole string. Consider using regular expressions and the -C construct instead. +C construct instead, or simply C. =item kill -This is identical to Perl's builtin C function. +This is identical to Perl's builtin C function for sending +signals to processes (oftern to terminate them), see L. =item labs +(For returning absolute values of long integers.) labs() is C-specific, see L instead. =item ldexp -This is identical to the C function C. +This is identical to the C function C +for multiplying floating point numbers with powers of two. + + $x_quadrupled = POSIX::ldexp($x, 2); =item ldiv +(For computing dividends of long integers.) ldiv() is C-specific, use C and C instead. =item link -This is identical to Perl's builtin C function. +This is identical to Perl's builtin C function +for creating hard links into files, see L. =item localeconv @@ -673,7 +703,8 @@ Here is how to query the database for the B (Deutsch or German) locale. =item localtime -This is identical to Perl's builtin C function. +This is identical to Perl's builtin C function for +converting seconds since the epoch to a date see L. =item log @@ -718,14 +749,23 @@ malloc() is C-specific. Perl does memory management transparently. =item mblen This is identical to the C function C. +Perl does not have any support for the wide and multibyte +characters of the C standards, so this might be a rather +useless function. =item mbstowcs This is identical to the C function C. +Perl does not have any support for the wide and multibyte +characters of the C standards, so this might be a rather +useless function. =item mbtowc This is identical to the C function C. +Perl does not have any support for the wide and multibyte +characters of the C standards, so this might be a rather +useless function. =item memchr @@ -860,7 +900,7 @@ Returns C on failure. This is identical to the C function C, which outputs to the standard error stream the specified message followed by ": " and the current error string. Use the C function and the C<$!> -variable instead, see L and L. +variable instead, see L and L. =item pipe @@ -905,11 +945,11 @@ qsort() is C-specific, see L instead. =item raise Sends the specified signal to the current process. -See also L and the C<$$> in L. +See also L and the C<$$> in L. =item rand -rand() is non-portable, see L instead. +C is non-portable, see L instead. =item read @@ -959,12 +999,14 @@ for removing (empty) directories, see L. =item scanf -scanf() is C-specific--use <> and regular expressions instead, +scanf() is C-specific, use EE and regular expressions instead, see L. =item setgid -Sets the real group id for this process. +Sets the real group identifier for this process. +Identical to assigning a value to the Perl's builtin C<$)> variable, +see L. =item setjmp @@ -1005,17 +1047,21 @@ out which locales are available in your system. =item setpgid -This is similar to the C function C. +This is similar to the C function C for +setting the process group identifier of the current process. Returns C on failure. =item setsid -This is identical to the C function C. +This is identical to the C function C for +setting the session identifier of the current process. =item setuid -Sets the real user id for this process. +Sets the real user identifier for this process. +Identical to assigning a value to the Perl's builtin C<$E> variable, +see L. =item sigaction @@ -1114,7 +1160,8 @@ see L. =item stat -This is identical to Perl's builtin C function. +This is identical to Perl's builtin C function +for retutning information about files and directories. =item strcat @@ -1126,7 +1173,7 @@ strchr() is C-specific, see L instead. =item strcmp -strcmp() is C-specific, use C instead, see L. +strcmp() is C-specific, use C or C instead, see L. =item strcoll @@ -1141,12 +1188,13 @@ strcpy() is C-specific, use C<=> instead, see L. =item strcspn -strcspn() is C-specific, use regular expressions instead. +strcspn() is C-specific, use regular expressions instead, +see L. =item strerror Returns the error string for the specified errno. -Identical to the string form of the C<$!>, see L. +Identical to the string form of the C<$!>, see L. =item strftime @@ -1191,7 +1239,8 @@ strncpy() is C-specific, use C<=> instead, see L. =item strpbrk -strpbrk() is C-specific, use regular expressions instead, see L. +strpbrk() is C-specific, use regular expressions instead, +see L. =item strrchr @@ -1334,7 +1383,7 @@ Returns C on failure. =item tcgetpgrp This is identical to the C function C for returning the -process group id of the foreground process group of the controlling +process group identifier of the foreground process group of the controlling terminal. =item tcsendbreak @@ -1347,7 +1396,7 @@ Returns C on failure. =item tcsetpgrp This is similar to the C function C for setting the -process group id of the foreground process group of the controlling +process group identifier of the foreground process group of the controlling terminal. Returns C on failure. @@ -1372,7 +1421,7 @@ seconds. =item tmpfile -Use method C instead. +Use method C instead, or see L. =item tmpnam @@ -1380,7 +1429,7 @@ Returns a name for a temporary file. $tmpfile = POSIX::tmpnam(); -See also the L module. +See also L. =item tolower @@ -1425,7 +1474,16 @@ see L. Get name of current operating system. - ($sysname, $nodename, $release, $version, $machine ) = POSIX::uname(); + ($sysname, $nodename, $release, $version, $machine) = POSIX::uname(); + +Note that the actual meanings of the various fields are not +that well standardized, do not expect any great portability. +The C<$sysname> might be the name of the operating system, +the C<$nodename> might be the name of the host, the C<$release> +might be the (major) release number of the operating system, +the C<$version> might be the (minor) release number of the +operating system, and the C<$machine> might be a hardware identifier. +Maybe. =item ungetc @@ -1470,10 +1528,16 @@ builtin C function, see L. =item wcstombs This is identical to the C function C. +Perl does not have any support for the wide and multibyte +characters of the C standards, so this might be a rather +useless function. =item wctomb This is identical to the C function C. +Perl does not have any support for the wide and multibyte +characters of the C standards, so this might be a rather +useless function. =item write @@ -1911,7 +1975,3 @@ WIFEXITED WEXITSTATUS WIFSIGNALED WTERMSIG WIFSTOPPED WSTOPSIG =back -=head1 CREATION - -This document generated by ./mkposixman.PL version 19960129. -