summaryrefslogtreecommitdiff
path: root/ext/POSIX/t
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2011-08-31 13:08:49 +0200
committerNicholas Clark <nick@ccl4.org>2011-09-01 21:54:11 +0200
commitfa22ee5499f30bb66e391725e58491665ffb05ae (patch)
tree7a4ae421314436909bacc8b68305f6701b6d2c48 /ext/POSIX/t
parentf8882ab154679fdb1be20392f3c1b47a8300e77a (diff)
downloadperl-fa22ee5499f30bb66e391725e58491665ffb05ae.tar.gz
Improvements to the diagnostics for "unimplemented" POSIX functions.
Suggested by Aristotle Pagaltzis as part of a larger refactoring. This regularises the text, changing '--use' and ': use' to ', use' to be consistent, provides a message for POSIX::srand(), and adds ' is' to the message for POSIX::bsearch(). Most of the diagnostics have been unchanged since perl 5.000. For some, IO::Handle replaced FileHandle in perl5.003_20 (28757baaaeaa3801). div and ldiv's messages were improved to also mention % in 2003 by commit 7a6ca5fd18d88091.
Diffstat (limited to 'ext/POSIX/t')
-rw-r--r--ext/POSIX/t/unimplemented.t44
1 files changed, 22 insertions, 22 deletions
diff --git a/ext/POSIX/t/unimplemented.t b/ext/POSIX/t/unimplemented.t
index eeb0d1bb3c..6ed6205045 100644
--- a/ext/POSIX/t/unimplemented.t
+++ b/ext/POSIX/t/unimplemented.t
@@ -9,11 +9,11 @@ plan(skip_all => "POSIX is unavailable")
require POSIX;
-foreach ([atexit => ' is C-specific: use END {} instead'],
+foreach ([atexit => ' is C-specific, use END {} instead'],
[atof => ' is C-specific, stopped'],
[atoi => ' is C-specific, stopped'],
[atol => ' is C-specific, stopped'],
- [bsearch => ' not supplied'],
+ [bsearch => ' is not supplied'],
[calloc => ' is C-specific, stopped'],
[clearerr => \'IO::Handle::clearerr'],
[div => ' is C-specific, use /, % and int instead'],
@@ -33,21 +33,21 @@ foreach ([atexit => ' is C-specific: use END {} instead'],
[fgets => \'IO::Handle::gets'],
[fileno => \'IO::Handle::fileno'],
[fopen => \'IO::File::open'],
- [fprintf => ' is C-specific--use printf instead'],
- [fputc => ' is C-specific--use print instead'],
- [fputs => ' is C-specific--use print instead'],
- [fread => ' is C-specific--use read instead'],
+ [fprintf => ' is C-specific, use printf instead'],
+ [fputc => ' is C-specific, use print instead'],
+ [fputs => ' is C-specific, use print instead'],
+ [fread => ' is C-specific, use read instead'],
[free => ' is C-specific, stopped'],
- [freopen => ' is C-specific--use open instead'],
- [fscanf => ' is C-specific--use <> and regular expressions instead'],
+ [freopen => ' is C-specific, use open instead'],
+ [fscanf => ' is C-specific, use <> and regular expressions instead'],
[fseek => \'IO::Seekable::seek'],
[fsetpos => \'IO::Seekable::setpos'],
[fsync => \'IO::Handle::sync'],
[ftell => \'IO::Seekable::tell'],
- [fwrite => ' is C-specific--use print instead'],
+ [fwrite => ' is C-specific, use print instead'],
[labs => ' is C-specific, use abs instead'],
[ldiv => ' is C-specific, use /, % and int instead'],
- [longjmp => ' is C-specific: use die instead'],
+ [longjmp => ' is C-specific, use die instead'],
[malloc => ' is C-specific, stopped'],
[memchr => ' is C-specific, use index() instead'],
[memcmp => ' is C-specific, use eq instead'],
@@ -55,20 +55,20 @@ foreach ([atexit => ' is C-specific: use END {} instead'],
[memmove => ' is C-specific, use = instead'],
[memset => ' is C-specific, use x instead'],
[offsetof => ' is C-specific, stopped'],
- [putc => ' is C-specific--use print instead'],
- [putchar => ' is C-specific--use print instead'],
- [puts => ' is C-specific--use print instead'],
+ [putc => ' is C-specific, use print instead'],
+ [putchar => ' is C-specific, use print instead'],
+ [puts => ' is C-specific, use print instead'],
[qsort => ' is C-specific, use sort instead'],
[rand => ' is non-portable, use Perl\'s rand instead'],
[realloc => ' is C-specific, stopped'],
- [scanf => ' is C-specific--use <> and regular expressions instead'],
+ [scanf => ' is C-specific, use <> and regular expressions instead'],
[setbuf => \'IO::Handle::setbuf'],
- [setjmp => ' is C-specific: use eval {} instead'],
+ [setjmp => ' is C-specific, use eval {} instead'],
[setvbuf => \'IO::Handle::setvbuf'],
- [siglongjmp => ' is C-specific: use die instead'],
- [sigsetjmp => ' is C-specific: use eval {} instead'],
- [srand => ''],
- [sscanf => ' is C-specific--use regular expressions instead'],
+ [siglongjmp => ' is C-specific, use die instead'],
+ [sigsetjmp => ' is C-specific, use eval {} instead'],
+ [srand => ' is not supplied, refer to Perl\'s srand documentation'],
+ [sscanf => ' is C-specific, use regular expressions instead'],
[strcat => ' is C-specific, use .= instead'],
[strchr => ' is C-specific, use index() instead'],
[strcmp => ' is C-specific, use eq instead'],
@@ -84,9 +84,9 @@ foreach ([atexit => ' is C-specific: use END {} instead'],
[strtok => ' is C-specific, stopped'],
[tmpfile => \'IO::File::new_tmpfile'],
[ungetc => \'IO::Handle::ungetc'],
- [vfprintf => ' is C-specific'],
- [vprintf => ' is C-specific'],
- [vsprintf => ' is C-specific'],
+ [vfprintf => ' is C-specific, stopped'],
+ [vprintf => ' is C-specific, stopped'],
+ [vsprintf => ' is C-specific, stopped'],
) {
my ($func, $action) = @$_;
my $expect = ref $action ? qr/Use method $$action\(\) instead at \(eval/