This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Integrate mainline
[perl5.git] / pod / perldiag.pod
CommitLineData
a0d0e21e
LW
1=head1 NAME
2
3perldiag - various Perl diagnostics
4
5=head1 DESCRIPTION
6
7These messages are classified as follows (listed in increasing order of
8desperation):
9
10 (W) A warning (optional).
11 (D) A deprecation (optional).
e476b1b5 12 (S) A severe warning (default).
a0d0e21e
LW
13 (F) A fatal error (trappable).
14 (P) An internal error you should never see (trappable).
54310121 15 (X) A very fatal error (nontrappable).
cb1a09d0 16 (A) An alien error message (not generated by Perl).
a0d0e21e 17
75b44862 18The majority of messages from the first three classifications above
64977eb6 19(W, D & S) can be controlled using the C<warnings> pragma.
e476b1b5
GS
20
21If a message can be controlled by the C<warnings> pragma, its warning
22category is included with the classification letter in the description
23below.
24
25Optional warnings are enabled by using the C<warnings> pragma or the B<-w>
26and B<-W> switches. Warnings may be captured by setting C<$SIG{__WARN__}>
27to a reference to a routine that will be called on each warning instead
28of printing it. See L<perlvar>.
29
30Default warnings are always enabled unless they are explicitly disabled
31with the C<warnings> pragma or the B<-X> switch.
4438c4b7 32
748a9306 33Trappable errors may be trapped using the eval operator. See
4438c4b7
JH
34L<perlfunc/eval>. In almost all cases, warnings may be selectively
35disabled or promoted to fatal errors using the C<warnings> pragma.
36See L<warnings>.
a0d0e21e 37
6df41af2
GS
38The messages are in alphabetical order, without regard to upper or
39lower-case. Some of these messages are generic. Spots that vary are
40denoted with a %s or other printf-style escape. These escapes are
41ignored by the alphabetical order, as are all characters other than
42letters. To look up your message, just ignore anything that is not a
43letter.
a0d0e21e
LW
44
45=over 4
46
c133c03f
JH
47=item A thread exited while %d other threads were still running
48
49(W) When using threaded Perl, a thread (not necessarily the main
50thread) exited while there were still other threads running.
51Usually it's a good idea to first collect the return values of the
52created threads by joining them, and only then exit from then main
53thread. See L<threads>.
54
6df41af2 55=item accept() on closed socket %s
33633739 56
be771a83
GS
57(W closed) You tried to do an accept on a closed socket. Did you forget
58to check the return value of your socket() call? See
59L<perlfunc/accept>.
33633739 60
6df41af2 61=item Allocation too large: %lx
a0d0e21e 62
6df41af2 63(X) You can't allocate more than 64K on an MS-DOS machine.
a0d0e21e 64
f61d411c 65=item '!' allowed only after types %s
ef54e1a4 66
f61d411c
JH
67(F) The '!' is allowed in pack() and unpack() only after certain types.
68See L<perlfunc/pack>.
ef54e1a4 69
6df41af2 70=item Ambiguous call resolved as CORE::%s(), qualify as such or use &
43192e07 71
75b44862 72(W ambiguous) A subroutine you have declared has the same name as a Perl
be771a83
GS
73keyword, and you have used the name without qualification for calling
74one or the other. Perl decided to call the builtin because the
75subroutine is not imported.
43192e07 76
6df41af2
GS
77To force interpretation as a subroutine call, either put an ampersand
78before the subroutine name, or qualify the name with its package.
79Alternatively, you can import the subroutine (or pretend that it's
80imported with the C<use subs> pragma).
43192e07 81
6df41af2 82To silently interpret it as the Perl operator, use the C<CORE::> prefix
496a33f5 83on the operator (e.g. C<CORE::log($x)>) or declare the subroutine
be771a83
GS
84to be an object method (see L<perlsub/"Subroutine Attributes"> or
85L<attributes>).
43192e07 86
c2e66d9e
GS
87=item Ambiguous range in transliteration operator
88
89(F) You wrote something like C<tr/a-z-0//> which doesn't mean anything at
90all. To include a C<-> character in a transliteration, put it either
91first or last. (In the past, C<tr/a-z-0//> was synonymous with
92C<tr/a-y//>, which was probably not what you would have expected.)
93
6df41af2 94=item Ambiguous use of %s resolved as %s
43192e07 95
6df41af2
GS
96(W ambiguous)(S) You said something that may not be interpreted the way
97you thought. Normally it's pretty easy to disambiguate it by supplying
98a missing quote, operator, parenthesis pair or declaration.
a0d0e21e 99
6df41af2 100=item '|' and '<' may not both be specified on command line
a0d0e21e 101
be771a83
GS
102(F) An error peculiar to VMS. Perl does its own command line
103redirection, and found that STDIN was a pipe, and that you also tried to
104redirect STDIN using '<'. Only one STDIN stream to a customer, please.
c9f97d15 105
6df41af2 106=item '|' and '>' may not both be specified on command line
1028017a 107
be771a83
GS
108(F) An error peculiar to VMS. Perl does its own command line
109redirection, and thinks you tried to redirect stdout both to a file and
110into a pipe to another command. You need to choose one or the other,
111though nothing's stopping you from piping into a program or Perl script
112which 'splits' output into two streams, such as
1028017a 113
6df41af2
GS
114 open(OUT,">$ARGV[0]") or die "Can't write to $ARGV[0]: $!";
115 while (<STDIN>) {
116 print;
117 print OUT;
118 }
119 close OUT;
c9f97d15 120
6df41af2 121=item Applying %s to %s will act on scalar(%s)
eb6e2d6f 122
496a33f5
SC
123(W misc) The pattern match (C<//>), substitution (C<s///>), and
124transliteration (C<tr///>) operators work on scalar values. If you apply
be771a83
GS
125one of them to an array or a hash, it will convert the array or hash to
126a scalar value -- the length of an array, or the population info of a
127hash -- and then work on that scalar value. This is probably not what
128you meant to do. See L<perlfunc/grep> and L<perlfunc/map> for
129alternatives.
eb6e2d6f 130
6df41af2 131=item Args must match #! line
a0d0e21e 132
6df41af2
GS
133(F) The setuid emulator requires that the arguments Perl was invoked
134with match the arguments specified on the #! line. Since some systems
135impose a one-argument limit on the #! line, try combining switches;
136for example, turn C<-w -U> into C<-wU>.
a0d0e21e 137
6df41af2 138=item Arg too short for msgsnd
76cd736e 139
6df41af2 140(F) msgsnd() requires a string at least as long as sizeof(long).
76cd736e 141
8ea97a1e 142=item %s argument is not a HASH or ARRAY element
a0d0e21e 143
8ea97a1e 144(F) The argument to exists() must be a hash or array element, such as:
a0d0e21e
LW
145
146 $foo{$bar}
cb4f522a 147 $ref->{"susie"}[12]
a0d0e21e 148
8ea97a1e 149=item %s argument is not a HASH or ARRAY element or slice
5f05dabc 150
be771a83
GS
151(F) The argument to delete() must be either a hash or array element,
152such as:
5f05dabc
PP
153
154 $foo{$bar}
cb4f522a 155 $ref->{"susie"}[12]
5f05dabc 156
8ea97a1e 157or a hash or array slice, such as:
5f05dabc 158
6df41af2
GS
159 @foo[$bar, $baz, $xyzzy]
160 @{$ref->[12]}{"susie", "queue"}
5315574d 161
6df41af2 162=item %s argument is not a subroutine name
a0d0e21e 163
6df41af2 164(F) The argument to exists() for C<exists &sub> must be a subroutine
be771a83
GS
165name, and not a subroutine call. C<exists &sub()> will generate this
166error.
a0d0e21e 167
f86702cc 168=item Argument "%s" isn't numeric%s
a0d0e21e 169
be771a83
GS
170(W numeric) The indicated string was fed as an argument to an operator
171that expected a numeric value instead. If you're fortunate the message
172will identify which operator was so unfortunate.
a0d0e21e
LW
173
174=item Array @%s missing the @ in argument %d of %s()
175
75b44862
GS
176(D deprecated) Really old Perl let you omit the @ on array names in some
177spots. This is now heavily deprecated.
a0d0e21e
LW
178
179=item assertion botched: %s
180
181(P) The malloc package that comes with Perl had an internal failure.
182
183=item Assertion failed: file "%s"
184
185(P) A general assertion failed. The file in question must be examined.
186
187=item Assignment to both a list and a scalar
188
189(F) If you assign to a conditional operator, the 2nd and 3rd arguments
190must either both be scalars or both be lists. Otherwise Perl won't
191know which context to supply to the right side.
192
2393f1b9 193=item Attempt to access disallowed key '%s' in a restricted hash
1b1f1335 194
49293501 195(F) The failing code has attempted to get or set a key which is not in
2393f1b9 196the current set of allowed keys of a restricted hash.
49293501 197
2393f1b9 198=item Attempt to clear a restricted hash
49293501 199
2393f1b9 200(F) It is currently not allowed to clear a restricted hash, even if the
49293501
MS
201new hash would contain the same keys as before. This may change in
202the future.
203
2393f1b9 204=item Attempt to delete readonly key '%s' from a restricted hash
49293501
MS
205
206(F) The failing code attempted to delete a key whose value has been
2393f1b9 207declared readonly from a restricted hash.
49293501 208
2393f1b9 209=item Attempt to delete disallowed key '%s' from a restricted hash
49293501 210
2393f1b9
JH
211(F) The failing code attempted to delete from a restricted hash a key
212which is not in its key set.
1b1f1335 213
81689caa
HS
214=item Attempt to bless into a reference
215
216(F) The CLASSNAME argument to the bless() operator is expected to be
217the name of the package to bless the resulting object into. You've
218supplied instead a reference to something: perhaps you wrote
219
220 bless $self, $proto;
221
222when you intended
223
224 bless $self, ref($proto) || $proto;
225
226If you actually want to bless into the stringified version
227of the reference supplied, you need to stringify it yourself, for
228example by:
229
230 bless $self, "$proto";
231
a0d0e21e
LW
232=item Attempt to free non-arena SV: 0x%lx
233
be771a83
GS
234(P internal) All SV objects are supposed to be allocated from arenas
235that will be garbage collected on exit. An SV was discovered to be
236outside any of those arenas.
a0d0e21e 237
54310121 238=item Attempt to free nonexistent shared string
bbce6d69 239
be771a83
GS
240(P internal) Perl maintains a reference counted internal table of
241strings to optimize the storage and access of hash keys and other
242strings. This indicates someone tried to decrement the reference count
243of a string that can no longer be found in the table.
bbce6d69 244
a0d0e21e
LW
245=item Attempt to free temp prematurely
246
be771a83
GS
247(W debugging) Mortalized values are supposed to be freed by the
248free_tmps() routine. This indicates that something else is freeing the
249SV before the free_tmps() routine gets a chance, which means that the
250free_tmps() routine will be freeing an unreferenced scalar when it does
251try to free it.
a0d0e21e
LW
252
253=item Attempt to free unreferenced glob pointers
254
e476b1b5 255(P internal) The reference counts got screwed up on symbol aliases.
a0d0e21e
LW
256
257=item Attempt to free unreferenced scalar
258
be771a83
GS
259(W internal) Perl went to decrement the reference count of a scalar to
260see if it would go to 0, and discovered that it had already gone to 0
261earlier, and should have been freed, and in fact, probably was freed.
262This could indicate that SvREFCNT_dec() was called too many times, or
263that SvREFCNT_inc() was called too few times, or that the SV was
264mortalized when it shouldn't have been, or that memory has been
265corrupted.
a0d0e21e 266
dcdda58d
GS
267=item Attempt to join self
268
269(F) You tried to join a thread from within itself, which is an
be771a83
GS
270impossible task. You may be joining the wrong thread, or you may need
271to move the join() to some other thread.
dcdda58d 272
84902520
TB
273=item Attempt to pack pointer to temporary value
274
be771a83
GS
275(W pack) You tried to pass a temporary value (like the result of a
276function, or a computed expression) to the "p" pack() template. This
277means the result contains a pointer to a location that could become
278invalid anytime, even before the end of the current statement. Use
279literals or global values as arguments to the "p" pack() template to
280avoid this warning.
84902520 281
b7a902f4
PP
282=item Attempt to use reference as lvalue in substr
283
be771a83
GS
284(W substr) You supplied a reference as the first argument to substr()
285used as an lvalue, which is pretty strange. Perhaps you forgot to
286dereference it first. See L<perlfunc/substr>.
b7a902f4 287
dc26df50 288=item Bad arg length for %s, is %d, should be %s
a0d0e21e 289
be771a83
GS
290(F) You passed a buffer of the wrong size to one of msgctl(), semctl()
291or shmctl(). In C parlance, the correct sizes are, respectively,
5f05dabc 292S<sizeof(struct msqid_ds *)>, S<sizeof(struct semid_ds *)>, and
a0d0e21e
LW
293S<sizeof(struct shmid_ds *)>.
294
7a95317d
GS
295=item Bad evalled substitution pattern
296
496a33f5 297(F) You've used the C</e> switch to evaluate the replacement for a
7a95317d
GS
298substitution, but perl found a syntax error in the code to evaluate,
299most likely an unexpected right brace '}'.
300
a0d0e21e
LW
301=item Bad filehandle: %s
302
be771a83
GS
303(F) A symbol was passed to something wanting a filehandle, but the
304symbol has no filehandle associated with it. Perhaps you didn't do an
305open(), or did it in another package.
a0d0e21e
LW
306
307=item Bad free() ignored
308
be771a83
GS
309(S malloc) An internal routine called free() on something that had never
310been malloc()ed in the first place. Mandatory, but can be disabled by
9ea8bc6d 311setting environment variable C<PERL_BADFREE> to 0.
33c8a3fe 312
9ea8bc6d 313This message can be seen quite often with DB_File on systems with "hard"
be771a83
GS
314dynamic linking, like C<AIX> and C<OS/2>. It is a bug of C<Berkeley DB>
315which is left unnoticed if C<DB> uses I<forgiving> system malloc().
a0d0e21e 316
aa689395
PP
317=item Bad hash
318
319(P) One of the internal hash routines was passed a null HV pointer.
320
f1192cee
GA
321=item Bad index while coercing array into hash
322
6f54a448
GS
323(F) The index looked up in the hash found as the 0'th element of a
324pseudo-hash is not legal. Index values must be at 1 or greater.
325See L<perlref>.
57079c46 326
6df41af2
GS
327=item Badly placed ()'s
328
329(A) You've accidentally run your script through B<csh> instead
330of Perl. Check the #! line, or manually feed your script into
331Perl yourself.
332
a0d0e21e
LW
333=item Bad name after %s::
334
be771a83
GS
335(F) You started to name a symbol by using a package prefix, and then
336didn't finish the symbol. In particular, you can't interpolate outside
337of quotes, so
a0d0e21e
LW
338
339 $var = 'myvar';
340 $sym = mypack::$var;
341
342is not the same as
343
344 $var = 'myvar';
345 $sym = "mypack::$var";
346
4ad56ec9
IZ
347=item Bad realloc() ignored
348
be771a83
GS
349(S malloc) An internal routine called realloc() on something that had
350never been malloc()ed in the first place. Mandatory, but can be disabled
351by setting environment variable C<PERL_BADFREE> to 1.
4ad56ec9 352
a0d0e21e
LW
353=item Bad symbol for array
354
355(P) An internal request asked to add an array entry to something that
356wasn't a symbol table entry.
357
358=item Bad symbol for filehandle
359
be771a83
GS
360(P) An internal request asked to add a filehandle entry to something
361that wasn't a symbol table entry.
a0d0e21e
LW
362
363=item Bad symbol for hash
364
365(P) An internal request asked to add a hash entry to something that
366wasn't a symbol table entry.
367
34d09196
GS
368=item Bareword found in conditional
369
be771a83
GS
370(W bareword) The compiler found a bareword where it expected a
371conditional, which often indicates that an || or && was parsed as part
372of the last argument of the previous construct, for example:
34d09196
GS
373
374 open FOO || die;
375
be771a83
GS
376It may also indicate a misspelled constant that has been interpreted as
377a bareword:
34d09196
GS
378
379 use constant TYPO => 1;
380 if (TYOP) { print "foo" }
381
382The C<strict> pragma is useful in avoiding such errors.
383
6df41af2
GS
384=item Bareword "%s" not allowed while "strict subs" in use
385
386(F) With "strict subs" in use, a bareword is only allowed as a
be771a83
GS
387subroutine identifier, in curly brackets or to the left of the "=>"
388symbol. Perhaps you need to predeclare a subroutine?
6df41af2
GS
389
390=item Bareword "%s" refers to nonexistent package
391
be771a83
GS
392(W bareword) You used a qualified bareword of the form C<Foo::>, but the
393compiler saw no other uses of that namespace before that point. Perhaps
394you need to predeclare a package?
6df41af2 395
a0d0e21e
LW
396=item BEGIN failed--compilation aborted
397
be771a83
GS
398(F) An untrapped exception was raised while executing a BEGIN
399subroutine. Compilation stops immediately and the interpreter is
400exited.
a0d0e21e 401
68dc0745
PP
402=item BEGIN not safe after errors--compilation aborted
403
404(F) Perl found a C<BEGIN {}> subroutine (or a C<use> directive, which
be771a83
GS
405implies a C<BEGIN {}>) after one or more compilation errors had already
406occurred. Since the intended environment for the C<BEGIN {}> could not
407be guaranteed (due to the errors), and since subsequent code likely
408depends on its correct operation, Perl just gave up.
68dc0745 409
6df41af2
GS
410=item \1 better written as $1
411
be771a83
GS
412(W syntax) Outside of patterns, backreferences live on as variables.
413The use of backslashes is grandfathered on the right-hand side of a
414substitution, but stylistically it's better to use the variable form
415because other Perl programmers will expect it, and it works better if
416there are more than 9 backreferences.
6df41af2 417
252aa082
JH
418=item Binary number > 0b11111111111111111111111111111111 non-portable
419
e476b1b5 420(W portable) The binary number you specified is larger than 2**32-1
9e24b6e2
JH
421(4294967295) and therefore non-portable between systems. See
422L<perlport> for more on portability concerns.
252aa082 423
69282e91 424=item bind() on closed socket %s
a0d0e21e 425
be771a83
GS
426(W closed) You tried to do a bind on a closed socket. Did you forget to
427check the return value of your socket() call? See L<perlfunc/bind>.
a0d0e21e 428
c289d2f7
JH
429=item binmode() on closed filehandle %s
430
431(W unopened) You tried binmode() on a filehandle that was never opened.
432Check you control flow and number of arguments.
433
c5a0f51a
JH
434=item Bit vector size > 32 non-portable
435
e476b1b5 436(W portable) Using bit vector sizes larger than 32 is non-portable.
c5a0f51a 437
4633a7c4
LW
438=item Bizarre copy of %s in %s
439
be771a83 440(P) Perl detected an attempt to copy an internal value that is not
b45f050a 441copyable.
4633a7c4 442
6df41af2
GS
443=item B<-P> not allowed for setuid/setgid script
444
445(F) The script would have to be opened by the C preprocessor by name,
446which provides a race condition that breaks security.
447
f675dbe5
CB
448=item Buffer overflow in prime_env_iter: %s
449
be771a83
GS
450(W internal) A warning peculiar to VMS. While Perl was preparing to
451iterate over %ENV, it encountered a logical name or symbol definition
452which was too long, so it was truncated to the string shown.
f675dbe5 453
a0d0e21e
LW
454=item Callback called exit
455
4929bf7b 456(F) A subroutine invoked from an external package via call_sv()
a0d0e21e
LW
457exited by calling exit.
458
6df41af2 459=item %s() called too early to check prototype
f675dbe5 460
be771a83
GS
461(W prototype) You've called a function that has a prototype before the
462parser saw a definition or declaration for it, and Perl could not check
463that the call conforms to the prototype. You need to either add an
464early prototype declaration for the subroutine in question, or move the
465subroutine definition ahead of the call to get proper prototype
466checking. Alternatively, if you are certain that you're calling the
467function correctly, you may put an ampersand before the name to avoid
468the warning. See L<perlsub>.
f675dbe5 469
6df41af2 470=item / cannot take a count
a0d0e21e 471
be771a83
GS
472(F) You had an unpack template indicating a counted-length string, but
473you have also specified an explicit size for the string. See
474L<perlfunc/pack>.
a0d0e21e
LW
475
476=item Can't bless non-reference value
477
478(F) Only hard references may be blessed. This is how Perl "enforces"
479encapsulation of objects. See L<perlobj>.
480
a0d0e21e
LW
481=item Can't call method "%s" in empty package "%s"
482
483(F) You called a method correctly, and it correctly indicated a package
484functioning as a class, but that package doesn't have ANYTHING defined
485in it, let alone methods. See L<perlobj>.
486
6df41af2
GS
487=item Can't call method "%s" on an undefined value
488
489(F) You used the syntax of a method call, but the slot filled by the
be771a83
GS
490object reference or package name contains an undefined value. Something
491like this will reproduce the error:
6df41af2
GS
492
493 $BADREF = undef;
494 process $BADREF 1,2,3;
495 $BADREF->process(1,2,3);
496
a0d0e21e
LW
497=item Can't call method "%s" on unblessed reference
498
54310121 499(F) A method call must know in what package it's supposed to run. It
be771a83
GS
500ordinarily finds this out from the object reference you supply, but you
501didn't supply an object reference in this case. A reference isn't an
502object reference until it has been blessed. See L<perlobj>.
a0d0e21e
LW
503
504=item Can't call method "%s" without a package or object reference
505
506(F) You used the syntax of a method call, but the slot filled by the
be771a83
GS
507object reference or package name contains an expression that returns a
508defined value which is neither an object reference nor a package name.
72b5445b
GS
509Something like this will reproduce the error:
510
511 $BADREF = 42;
512 process $BADREF 1,2,3;
513 $BADREF->process(1,2,3);
514
a0d0e21e
LW
515=item Can't chdir to %s
516
517(F) You called C<perl -x/foo/bar>, but C</foo/bar> is not a directory
518that you can chdir to, possibly because it doesn't exist.
519
0545a864 520=item Can't check filesystem of script "%s" for nosuid
104d25b7 521
be771a83
GS
522(P) For some reason you can't check the filesystem of the script for
523nosuid.
104d25b7 524
6df41af2
GS
525=item Can't coerce array into hash
526
527(F) You used an array where a hash was expected, but the array has no
528information on how to map from keys to array indices. You can do that
529only with arrays that have a hash reference at index 0.
530
a0d0e21e
LW
531=item Can't coerce %s to integer in %s
532
533(F) Certain types of SVs, in particular real symbol table entries
55497cff 534(typeglobs), can't be forced to stop being what they are. So you can't
a0d0e21e
LW
535say things like:
536
537 *foo += 1;
538
539You CAN say
540
541 $foo = *foo;
542 $foo += 1;
543
544but then $foo no longer contains a glob.
545
546=item Can't coerce %s to number in %s
547
548(F) Certain types of SVs, in particular real symbol table entries
55497cff 549(typeglobs), can't be forced to stop being what they are.
a0d0e21e
LW
550
551=item Can't coerce %s to string in %s
552
553(F) Certain types of SVs, in particular real symbol table entries
55497cff 554(typeglobs), can't be forced to stop being what they are.
a0d0e21e
LW
555
556=item Can't create pipe mailbox
557
be771a83
GS
558(P) An error peculiar to VMS. The process is suffering from exhausted
559quotas or other plumbing problems.
a0d0e21e 560
eb64745e 561=item Can't declare class for non-scalar %s in "%s"
a0d0e21e 562
2f7e735d
AMS
563(F) Currently, only scalar variables can be declared with a specific
564class qualifier in a "my" or "our" declaration. The semantics may be
565extended for other types of variables in future.
eb64745e
GS
566
567=item Can't declare %s in "%s"
568
569(F) Only scalar, array, and hash variables may be declared as "my" or
570"our" variables. They must have ordinary identifiers as names.
a0d0e21e 571
6df41af2
GS
572=item Can't do inplace edit: %s is not a regular file
573
be771a83
GS
574(S inplace) You tried to use the B<-i> switch on a special file, such as
575a file in /dev, or a FIFO. The file was ignored.
6df41af2 576
a0d0e21e
LW
577=item Can't do inplace edit on %s: %s
578
be771a83
GS
579(S inplace) The creation of the new file failed for the indicated
580reason.
a0d0e21e 581
54310121 582=item Can't do inplace edit without backup
a0d0e21e 583
be771a83
GS
584(F) You're on a system such as MS-DOS that gets confused if you try
585reading from a deleted (but still opened) file. You have to say
586C<-i.bak>, or some such.
a0d0e21e 587
10f9c03d 588=item Can't do inplace edit: %s would not be unique
a0d0e21e 589
e476b1b5 590(S inplace) Your filesystem does not support filenames longer than 14
10f9c03d
CK
591characters and Perl was unable to create a unique filename during
592inplace editing with the B<-i> switch. The file was ignored.
a0d0e21e 593
7253e4e3 594=item Can't do {n,m} with n > m in regex; marked by <-- HERE in m/%s/
a0d0e21e 595
b45f050a 596(F) Minima must be less than or equal to maxima. If you really want your
7253e4e3 597regexp to match something 0 times, just put {0}. The <-- HERE shows in the
b45f050a 598regular expression about where the problem was discovered. See L<perlre>.
a0d0e21e
LW
599
600=item Can't do setegid!
601
be771a83
GS
602(P) The setegid() call failed for some reason in the setuid emulator of
603suidperl.
a0d0e21e
LW
604
605=item Can't do seteuid!
606
607(P) The setuid emulator of suidperl failed for some reason.
608
609=item Can't do setuid
610
be771a83
GS
611(F) This typically means that ordinary perl tried to exec suidperl to do
612setuid emulation, but couldn't exec it. It looks for a name of the form
613sperl5.000 in the same directory that the perl executable resides under
614the name perl5.000, typically /usr/local/bin on Unix machines. If the
615file is there, check the execute permissions. If it isn't, ask your
616sysadmin why he and/or she removed it.
a0d0e21e
LW
617
618=item Can't do waitpid with flags
619
be771a83
GS
620(F) This machine doesn't have either waitpid() or wait4(), so only
621waitpid() without flags is emulated.
a0d0e21e 622
a0d0e21e
LW
623=item Can't emulate -%s on #! line
624
be771a83
GS
625(F) The #! line specifies a switch that doesn't make sense at this
626point. For example, it'd be kind of silly to put a B<-x> on the #!
627line.
a0d0e21e
LW
628
629=item Can't exec "%s": %s
630
d1be9408 631(W exec) A system(), exec(), or piped open call could not execute the
be771a83
GS
632named program for the indicated reason. Typical reasons include: the
633permissions were wrong on the file, the file wasn't found in
634C<$ENV{PATH}>, the executable in question was compiled for another
635architecture, or the #! line in a script points to an interpreter that
636can't be run for similar reasons. (Or maybe your system doesn't support
637#! at all.)
a0d0e21e
LW
638
639=item Can't exec %s
640
be771a83
GS
641(F) Perl was trying to execute the indicated program for you because
642that's what the #! line said. If that's not what you wanted, you may
643need to mention "perl" on the #! line somewhere.
a0d0e21e
LW
644
645=item Can't execute %s
646
be771a83
GS
647(F) You used the B<-S> switch, but the copies of the script to execute
648found in the PATH did not have correct permissions.
2a92aaa0 649
6df41af2 650=item Can't find an opnumber for "%s"
2a92aaa0 651
be771a83
GS
652(F) A string of a form C<CORE::word> was given to prototype(), but there
653is no builtin with the name C<word>.
6df41af2 654
56ca2fc0
JH
655=item Can't find %s character property "%s"
656
657(F) You used C<\p{}> or C<\P{}> but the character property by that name
89d60977 658could not be found. Maybe you misspelled the name of the property
56ca2fc0
JH
659(remember that the names of character properties consist only of
660alphanumeric characters), or maybe you forgot the C<Is> or C<In> prefix?
661
6df41af2
GS
662=item Can't find label %s
663
be771a83
GS
664(F) You said to goto a label that isn't mentioned anywhere that it's
665possible for us to go to. See L<perlfunc/goto>.
2a92aaa0
GS
666
667=item Can't find %s on PATH
668
be771a83
GS
669(F) You used the B<-S> switch, but the script to execute could not be
670found in the PATH.
a0d0e21e 671
6df41af2 672=item Can't find %s on PATH, '.' not in PATH
a0d0e21e 673
be771a83
GS
674(F) You used the B<-S> switch, but the script to execute could not be
675found in the PATH, or at least not with the correct permissions. The
676script exists in the current directory, but PATH prohibits running it.
a0d0e21e
LW
677
678=item Can't find string terminator %s anywhere before EOF
679
be771a83
GS
680(F) Perl strings can stretch over multiple lines. This message means
681that the closing delimiter was omitted. Because bracketed quotes count
682nesting levels, the following is missing its final parenthesis:
a0d0e21e 683
fb73857a
PP
684 print q(The character '(' starts a side comment.);
685
be771a83
GS
686If you're getting this error from a here-document, you may have included
687unseen whitespace before or after your closing tag. A good programmer's
688editor will have a way to help you find these characters.
a0d0e21e 689
64977eb6 690=item Can't find %s property definition %s
0103b764 691
f91328b7 692(F) You may have tried to use C<\p> which means a Unicode property for
bc45ce41
JH
693example \p{Lu} is all uppercase letters. if you did mean to use a
694Unicode property, see L<perlunicode> for the list of known properties.
695If you didn't mean to use a Unicode property, escape the C<\p>, either
f91328b7
JH
696C<\\p> (just the C<\p>) or by C<\Q\p> (the rest of the string, until
697possible C<\E>).
0103b764 698
a0d0e21e
LW
699=item Can't fork
700
be771a83
GS
701(F) A fatal error occurred while trying to fork while opening a
702pipeline.
a0d0e21e 703
748a9306
LW
704=item Can't get filespec - stale stat buffer?
705
be771a83
GS
706(S) A warning peculiar to VMS. This arises because of the difference
707between access checks under VMS and under the Unix model Perl assumes.
708Under VMS, access checks are done by filename, rather than by bits in
709the stat buffer, so that ACLs and other protections can be taken into
710account. Unfortunately, Perl assumes that the stat buffer contains all
711the necessary information, and passes it, instead of the filespec, to
712the access checking routine. It will try to retrieve the filespec using
713the device name and FID present in the stat buffer, but this works only
714if you haven't made a subsequent call to the CRTL stat() routine,
715because the device name is overwritten with each call. If this warning
716appears, the name lookup failed, and the access checking routine gave up
717and returned FALSE, just to be conservative. (Note: The access checking
718routine knows about the Perl C<stat> operator and file tests, so you
719shouldn't ever see this warning in response to a Perl command; it arises
720only if some internal code takes stat buffers lightly.)
748a9306 721
a0d0e21e
LW
722=item Can't get pipe mailbox device name
723
be771a83
GS
724(P) An error peculiar to VMS. After creating a mailbox to act as a
725pipe, Perl can't retrieve its name for later use.
a0d0e21e
LW
726
727=item Can't get SYSGEN parameter value for MAXBUF
728
748a9306
LW
729(P) An error peculiar to VMS. Perl asked $GETSYI how big you want your
730mailbox buffers to be, and didn't get an answer.
a0d0e21e 731
6df41af2 732=item Can't "goto" into the middle of a foreach loop
a0d0e21e 733
be771a83
GS
734(F) A "goto" statement was executed to jump into the middle of a foreach
735loop. You can't get there from here. See L<perlfunc/goto>.
6df41af2
GS
736
737=item Can't "goto" out of a pseudo block
738
be771a83
GS
739(F) A "goto" statement was executed to jump out of what might look like
740a block, except that it isn't a proper block. This usually occurs if
741you tried to jump out of a sort() block or subroutine, which is a no-no.
742See L<perlfunc/goto>.
a0d0e21e 743
b150fb22
RH
744=item Can't goto subroutine from an eval-string
745
be771a83
GS
746(F) The "goto subroutine" call can't be used to jump out of an eval
747"string". (You can use it to jump out of an eval {BLOCK}, but you
748probably don't want to.)
b150fb22 749
6df41af2
GS
750=item Can't goto subroutine outside a subroutine
751
be771a83
GS
752(F) The deeply magical "goto subroutine" call can only replace one
753subroutine call for another. It can't manufacture one out of whole
754cloth. In general you should be calling it out of only an AUTOLOAD
755routine anyway. See L<perlfunc/goto>.
6df41af2 756
0b5b802d
GS
757=item Can't ignore signal CHLD, forcing to default
758
be771a83
GS
759(W signal) Perl has detected that it is being run with the SIGCHLD
760signal (sometimes known as SIGCLD) disabled. Since disabling this
761signal will interfere with proper determination of exit status of child
762processes, Perl has reset the signal to its default value. This
763situation typically indicates that the parent program under which Perl
764may be running (e.g. cron) is being very careless.
0b5b802d 765
6df41af2 766=item Can't "last" outside a loop block
4633a7c4 767
6df41af2 768(F) A "last" statement was executed to break out of the current block,
be771a83
GS
769except that there's this itty bitty problem called there isn't a current
770block. Note that an "if" or "else" block doesn't count as a "loopish"
771block, as doesn't a block given to sort(), map() or grep(). You can
772usually double the curlies to get the same effect though, because the
773inner curlies will be considered a block that loops once. See
774L<perlfunc/last>.
4633a7c4 775
748a9306
LW
776=item Can't localize lexical variable %s
777
2ba9eb46 778(F) You used local on a variable name that was previously declared as a
748a9306
LW
779lexical variable using "my". This is not allowed. If you want to
780localize a package variable of the same name, qualify it with the
781package name.
782
0ebe0038
SM
783=item Can't localize pseudo-hash element
784
be771a83
GS
785(F) You said something like C<< local $ar->{'key'} >>, where $ar is a
786reference to a pseudo-hash. That hasn't been implemented yet, but you
787can get a similar effect by localizing the corresponding array element
788directly -- C<< local $ar->[$ar->[0]{'key'}] >>.
0ebe0038 789
6df41af2 790=item Can't localize through a reference
4727527e 791
6df41af2
GS
792(F) You said something like C<local $$ref>, which Perl can't currently
793handle, because when it goes to restore the old value of whatever $ref
be771a83 794pointed to after the scope of the local() is finished, it can't be sure
64977eb6 795that $ref will still be a reference.
4727527e 796
ea071790 797=item Can't locate %s
ec889f3a
GS
798
799(F) You said to C<do> (or C<require>, or C<use>) a file that couldn't be
800found. Perl looks for the file in all the locations mentioned in @INC,
be771a83
GS
801unless the file name included the full path to the file. Perhaps you
802need to set the PERL5LIB or PERL5OPT environment variable to say where
803the extra library is, or maybe the script needs to add the library name
804to @INC. Or maybe you just misspelled the name of the file. See
805L<perlfunc/require> and L<lib>.
a0d0e21e 806
6df41af2
GS
807=item Can't locate auto/%s.al in @INC
808
be771a83
GS
809(F) A function (or method) was called in a package which allows
810autoload, but there is no function to autoload. Most probable causes
811are a misprint in a function/method name or a failure to C<AutoSplit>
812the file, say, by doing C<make install>.
6df41af2 813
a0d0e21e
LW
814=item Can't locate object method "%s" via package "%s"
815
816(F) You called a method correctly, and it correctly indicated a package
817functioning as a class, but that package doesn't define that particular
2ba9eb46 818method, nor does any of its base classes. See L<perlobj>.
a0d0e21e 819
91c54917
NIS
820=item Can't locate PerlIO%s
821
822(F) You tried to use in open() a PerlIO layer that does not exist,
823e.g. open(FH, ">:nosuchlayer", "somefile").
824
c1899e02
GS
825=item (perhaps you forgot to load "%s"?)
826
827(F) This is an educated guess made in conjunction with the message
828"Can't locate object method \"%s\" via package \"%s\"". It often means
829that a method requires a package that has not been loaded.
830
a0d0e21e
LW
831=item Can't locate package %s for @%s::ISA
832
be771a83
GS
833(W syntax) The @ISA array contained the name of another package that
834doesn't seem to exist.
a0d0e21e 835
3e3baf6d
TB
836=item Can't make list assignment to \%ENV on this system
837
be771a83
GS
838(F) List assignment to %ENV is not supported on some systems, notably
839VMS.
3e3baf6d 840
a0d0e21e
LW
841=item Can't modify %s in %s
842
be771a83
GS
843(F) You aren't allowed to assign to the item indicated, or otherwise try
844to change it, such as with an auto-increment.
a0d0e21e 845
54310121 846=item Can't modify nonexistent substring
a0d0e21e
LW
847
848(P) The internal routine that does assignment to a substr() was handed
849a NULL.
850
6df41af2
GS
851=item Can't modify non-lvalue subroutine call
852
853(F) Subroutines meant to be used in lvalue context should be declared as
854such, see L<perlsub/"Lvalue subroutines">.
855
5f05dabc 856=item Can't msgrcv to read-only var
a0d0e21e 857
5f05dabc 858(F) The target of a msgrcv must be modifiable to be used as a receive
a0d0e21e
LW
859buffer.
860
6df41af2
GS
861=item Can't "next" outside a loop block
862
863(F) A "next" statement was executed to reiterate the current block, but
864there isn't a current block. Note that an "if" or "else" block doesn't
be771a83
GS
865count as a "loopish" block, as doesn't a block given to sort(), map() or
866grep(). You can usually double the curlies to get the same effect
867though, because the inner curlies will be considered a block that loops
868once. See L<perlfunc/next>.
6df41af2 869
a0d0e21e
LW
870=item Can't open %s: %s
871
c47ff5f1 872(S inplace) The implicit opening of a file through use of the C<< <> >>
08e9d68e
DD
873filehandle, either implicitly under the C<-n> or C<-p> command-line
874switches, or explicitly, failed for the indicated reason. Usually this
be771a83
GS
875is because you don't have read permission for a file which you named on
876the command line.
a0d0e21e 877
9a869a14
RGS
878=item Can't open a reference
879
880(W io) You tried to open a scalar reference for reading or writing,
881using the 3-arg open() syntax :
882
883 open FH, '>', $ref;
884
885but your version of perl is compiled without perlio, and this form of
886open is not supported.
887
a0d0e21e
LW
888=item Can't open bidirectional pipe
889
be771a83
GS
890(W pipe) You tried to say C<open(CMD, "|cmd|")>, which is not supported.
891You can try any of several modules in the Perl library to do this, such
892as IPC::Open2. Alternately, direct the pipe's output to a file using
893">", and then read it in under a different file handle.
a0d0e21e 894
748a9306
LW
895=item Can't open error file %s as stderr
896
be771a83
GS
897(F) An error peculiar to VMS. Perl does its own command line
898redirection, and couldn't open the file specified after '2>' or '2>>' on
899the command line for writing.
748a9306
LW
900
901=item Can't open input file %s as stdin
902
be771a83
GS
903(F) An error peculiar to VMS. Perl does its own command line
904redirection, and couldn't open the file specified after '<' on the
905command line for reading.
748a9306
LW
906
907=item Can't open output file %s as stdout
908
be771a83
GS
909(F) An error peculiar to VMS. Perl does its own command line
910redirection, and couldn't open the file specified after '>' or '>>' on
911the command line for writing.
748a9306
LW
912
913=item Can't open output pipe (name: %s)
914
be771a83
GS
915(P) An error peculiar to VMS. Perl does its own command line
916redirection, and couldn't open the pipe into which to send data destined
917for stdout.
748a9306 918
584d69ec 919=item Can't open perl script%s: %s
a0d0e21e
LW
920
921(F) The script you specified can't be opened for the indicated reason.
922
6df41af2
GS
923=item Can't read CRTL environ
924
925(S) A warning peculiar to VMS. Perl tried to read an element of %ENV
926from the CRTL's internal environment array and discovered the array was
927missing. You need to figure out where your CRTL misplaced its environ
be771a83
GS
928or define F<PERL_ENV_TABLES> (see L<perlvms>) so that environ is not
929searched.
6df41af2 930
7bac28a0
PP
931=item Can't redefine active sort subroutine %s
932
933(F) Perl optimizes the internal handling of sort subroutines and keeps
be771a83
GS
934pointers into them. You tried to redefine one such sort subroutine when
935it was currently active, which is not allowed. If you really want to do
7bac28a0
PP
936this, you should write C<sort { &func } @x> instead of C<sort func @x>.
937
6df41af2
GS
938=item Can't "redo" outside a loop block
939
940(F) A "redo" statement was executed to restart the current block, but
941there isn't a current block. Note that an "if" or "else" block doesn't
942count as a "loopish" block, as doesn't a block given to sort(), map()
943or grep(). You can usually double the curlies to get the same effect
944though, because the inner curlies will be considered a block that
945loops once. See L<perlfunc/redo>.
946
64977eb6 947=item Can't remove %s: %s, skipping file
10f9c03d 948
be771a83
GS
949(S inplace) You requested an inplace edit without creating a backup
950file. Perl was unable to remove the original file to replace it with
951the modified file. The file was left unmodified.
10f9c03d 952
a0d0e21e
LW
953=item Can't rename %s to %s: %s, skipping file
954
e476b1b5 955(S inplace) The rename done by the B<-i> switch failed for some reason,
10f9c03d 956probably because you don't have write permission to the directory.
a0d0e21e 957
748a9306
LW
958=item Can't reopen input pipe (name: %s) in binary mode
959
be771a83
GS
960(P) An error peculiar to VMS. Perl thought stdin was a pipe, and tried
961to reopen it to accept binary data. Alas, it failed.
748a9306 962
6df41af2
GS
963=item Can't resolve method `%s' overloading `%s' in package `%s'
964
be771a83
GS
965(F|P) Error resolving overloading specified by a method name (as opposed
966to a subroutine reference): no such method callable via the package. If
967method name is C<???>, this is an internal error.
6df41af2 968
a0d0e21e
LW
969=item Can't reswap uid and euid
970
be771a83
GS
971(P) The setreuid() call failed for some reason in the setuid emulator of
972suidperl.
a0d0e21e 973
cd06dffe
GS
974=item Can't return %s from lvalue subroutine
975
be771a83
GS
976(F) Perl detected an attempt to return illegal lvalues (such as
977temporary or readonly values) from a subroutine used as an lvalue. This
978is not allowed.
cd06dffe 979
78f9721b
SM
980=item Can't return %s to lvalue scalar context
981
982(F) You tried to return a complete array or hash from an lvalue subroutine,
983but you called the subroutine in a way that made Perl think you meant
984to return only one value. You probably meant to write parentheses around
985the call to the subroutine, which tell Perl that the call should be in
986list context.
987
6df41af2
GS
988=item Can't return outside a subroutine
989
990(F) The return statement was executed in mainline code, that is, where
991there was no subroutine call to return out of. See L<perlsub>.
992
a0d0e21e
LW
993=item Can't stat script "%s"
994
be771a83
GS
995(P) For some reason you can't fstat() the script even though you have it
996open already. Bizarre.
a0d0e21e
LW
997
998=item Can't swap uid and euid
999
be771a83
GS
1000(P) The setreuid() call failed for some reason in the setuid emulator of
1001suidperl.
a0d0e21e
LW
1002
1003=item Can't take log of %g
1004
fb73857a
PP
1005(F) For ordinary real numbers, you can't take the logarithm of a
1006negative number or zero. There's a Math::Complex package that comes
be771a83
GS
1007standard with Perl, though, if you really want to do that for the
1008negative numbers.
a0d0e21e
LW
1009
1010=item Can't take sqrt of %g
1011
1012(F) For ordinary real numbers, you can't take the square root of a
fb73857a
PP
1013negative number. There's a Math::Complex package that comes standard
1014with Perl, though, if you really want to do that.
a0d0e21e
LW
1015
1016=item Can't undef active subroutine
1017
1018(F) You can't undefine a routine that's currently running. You can,
1019however, redefine it while it's running, and you can even undef the
1020redefined subroutine while the old routine is running. Go figure.
1021
1022=item Can't unshift
1023
1024(F) You tried to unshift an "unreal" array that can't be unshifted, such
1025as the main Perl stack.
1026
1027=item Can't upgrade that kind of scalar
1028
be771a83
GS
1029(P) The internal sv_upgrade routine adds "members" to an SV, making it
1030into a more specialized kind of SV. The top several SV types are so
1031specialized, however, that they cannot be interconverted. This message
1032indicates that such a conversion was attempted.
a0d0e21e
LW
1033
1034=item Can't upgrade to undef
1035
be771a83
GS
1036(P) The undefined SV is the bottom of the totem pole, in the scheme of
1037upgradability. Upgrading to undef indicates an error in the code
1038calling sv_upgrade.
a0d0e21e 1039
6df41af2
GS
1040=item Can't use an undefined value as %s reference
1041
1042(F) A value used as either a hard reference or a symbolic reference must
1043be a defined value. This helps to delurk some insidious errors.
1044
1db89ea5
BS
1045=item Can't use anonymous symbol table for method lookup
1046
1047(P) The internal routine that does method lookup was handed a symbol
1048table that doesn't have a name. Symbol tables can become anonymous
1049for example by undefining stashes: C<undef %Some::Package::>.
1050
6df41af2
GS
1051=item Can't use bareword ("%s") as %s ref while "strict refs" in use
1052
be771a83
GS
1053(F) Only hard references are allowed by "strict refs". Symbolic
1054references are disallowed. See L<perlref>.
6df41af2 1055
90b75b61 1056=item Can't use %! because Errno.pm is not available
1d2dff63
GS
1057
1058(F) The first time the %! hash is used, perl automatically loads the
1059Errno.pm module. The Errno module is expected to tie the %! hash to
1060provide symbolic names for C<$!> errno values.
1061
6df41af2
GS
1062=item Can't use %s for loop variable
1063
be771a83
GS
1064(F) Only a simple scalar variable may be used as a loop variable on a
1065foreach.
6df41af2
GS
1066
1067=item Can't use global %s in "my"
1068
be771a83
GS
1069(F) You tried to declare a magical variable as a lexical variable. This
1070is not allowed, because the magic can be tied to only one location
1071(namely the global variable) and it would be incredibly confusing to
1072have variables in your program that looked like magical variables but
6df41af2
GS
1073weren't.
1074
c07a80fd
PP
1075=item Can't use "my %s" in sort comparison
1076
1077(F) The global variables $a and $b are reserved for sort comparisons.
c47ff5f1 1078You mentioned $a or $b in the same line as the <=> or cmp operator,
c07a80fd
PP
1079and the variable had earlier been declared as a lexical variable.
1080Either qualify the sort variable with the package name, or rename the
1081lexical variable.
1082
a0d0e21e
LW
1083=item Can't use %s ref as %s ref
1084
1085(F) You've mixed up your reference types. You have to dereference a
1086reference of the type needed. You can use the ref() function to
1087test the type of the reference, if need be.
1088
748a9306 1089=item Can't use string ("%s") as %s ref while "strict refs" in use
a0d0e21e 1090
be771a83
GS
1091(F) Only hard references are allowed by "strict refs". Symbolic
1092references are disallowed. See L<perlref>.
a0d0e21e 1093
748a9306
LW
1094=item Can't use subscript on %s
1095
1096(F) The compiler tried to interpret a bracketed expression as a
1097subscript. But to the left of the brackets was an expression that
1098didn't look like an array reference, or anything else subscriptable.
1099
6df41af2
GS
1100=item Can't use \%c to mean $%c in expression
1101
75b44862
GS
1102(W syntax) In an ordinary expression, backslash is a unary operator that
1103creates a reference to its argument. The use of backslash to indicate a
1104backreference to a matched substring is valid only as part of a regular
be771a83
GS
1105expression pattern. Trying to do this in ordinary Perl code produces a
1106value that prints out looking like SCALAR(0xdecaf). Use the $1 form
1107instead.
6df41af2 1108
810b8aa5
GS
1109=item Can't weaken a nonreference
1110
1111(F) You attempted to weaken something that was not a reference. Only
1112references can be weakened.
1113
5f05dabc 1114=item Can't x= to read-only value
a0d0e21e 1115
be771a83
GS
1116(F) You tried to repeat a constant value (often the undefined value)
1117with an assignment operator, which implies modifying the value itself.
a0d0e21e
LW
1118Perhaps you need to copy the value to a temporary, and repeat that.
1119
ac7cd81a
SC
1120=item Character in "C" format wrapped
1121
1122(W pack) You said
1123
1124 pack("C", $x)
1125
1126where $x is either less than 0 or more than 255; the C<"C"> format is
1127only for encoding native operating system characters (ASCII, EBCDIC,
1128and so on) and not for Unicode characters, so Perl behaved as if you meant
1129
1130 pack("C", $x & 255)
1131
1132If you actually want to pack Unicode codepoints, use the C<"U"> format
1133instead.
1134
1135=item Character in "c" format wrapped
1136
1137(W pack) You said
1138
1139 pack("c", $x)
1140
1141where $x is either less than -128 or more than 127; the C<"c"> format
1142is only for encoding native operating system characters (ASCII, EBCDIC,
1143and so on) and not for Unicode characters, so Perl behaved as if you meant
1144
1145 pack("c", $x & 255);
1146
1147If you actually want to pack Unicode codepoints, use the C<"U"> format
1148instead.
1149
9ddeeac9 1150=item close() on unopened filehandle %s
a0d0e21e 1151
e476b1b5 1152(W unopened) You tried to close a filehandle that was never opened.
a0d0e21e 1153
6df41af2
GS
1154=item %s: Command not found
1155
be771a83
GS
1156(A) You've accidentally run your script through B<csh> instead of Perl.
1157Check the #! line, or manually feed your script into Perl yourself.
6df41af2 1158
7a2e2cd6
PP
1159=item Compilation failed in require
1160
1161(F) Perl could not compile a file specified in a C<require> statement.
be771a83
GS
1162Perl uses this generic message when none of the errors that it
1163encountered were severe enough to halt compilation immediately.
7a2e2cd6 1164
c3464db5
DD
1165=item Complex regular subexpression recursion limit (%d) exceeded
1166
be771a83
GS
1167(W regexp) The regular expression engine uses recursion in complex
1168situations where back-tracking is required. Recursion depth is limited
1169to 32766, or perhaps less in architectures where the stack cannot grow
1170arbitrarily. ("Simple" and "medium" situations are handled without
1171recursion and are not subject to a limit.) Try shortening the string
1172under examination; looping in Perl code (e.g. with C<while>) rather than
1173in the regular expression engine; or rewriting the regular expression so
c2e66d9e 1174that it is simpler or backtracks less. (See L<perlfaq2> for information
be771a83 1175on I<Mastering Regular Expressions>.)
c3464db5 1176
38875929
DM
1177=item cond_broadcast() called on unlocked variable
1178
1179(W threads) Within a thread-enabled program, you tried to call
1180cond_broadcast() on a variable which wasn't locked. The cond_broadcast()
1181function is used to wake up another thread that is waiting in a
1182cond_wait(). To ensure that the signal isn't sent before the other thread
1183has a chance to enter the wait, it is usual for the signaling thread to
1184first wait for a lock on variable. This lock attempt will only succeed
1185after the other thread has entered cond_wait() and thus relinquished the
1186lock.
1187
1188
1189=item cond_signal() called on unlocked variable
1190
1191(W threads) Within a thread-enabled program, you tried to call
1192cond_signal() on a variable which wasn't locked. The cond_signal()
1193function is used to wake up another thread that is waiting in a
1194cond_wait(). To ensure that the signal isn't sent before the other thread
1195has a chance to enter the wait, it is usual for the signaling thread to
1196first wait for a lock on variable. This lock attempt will only succeed
1197after the other thread has entered cond_wait() and thus relinquished the
1198lock.
1199
69282e91 1200=item connect() on closed socket %s
a0d0e21e 1201
be771a83
GS
1202(W closed) You tried to do a connect on a closed socket. Did you forget
1203to check the return value of your socket() call? See
1204L<perlfunc/connect>.
a0d0e21e 1205
41ab332f 1206=item Constant(%s)%s: %s
6df41af2 1207
be771a83
GS
1208(F) The parser found inconsistencies either while attempting to define
1209an overloaded constant, or when trying to find the character name
1210specified in the C<\N{...}> escape. Perhaps you forgot to load the
1211corresponding C<overload> or C<charnames> pragma? See L<charnames> and
1212L<overload>.
6df41af2 1213
779c5bc9
GS
1214=item Constant is not %s reference
1215
1216(F) A constant value (perhaps declared using the C<use constant> pragma)
be771a83
GS
1217is being dereferenced, but it amounts to the wrong type of reference.
1218The message indicates the type of reference that was expected. This
1219usually indicates a syntax error in dereferencing the constant value.
779c5bc9
GS
1220See L<perlsub/"Constant Functions"> and L<constant>.
1221
4cee8e80
CS
1222=item Constant subroutine %s redefined
1223
bb028877 1224(S) You redefined a subroutine which had previously been
be771a83
GS
1225eligible for inlining. See L<perlsub/"Constant Functions"> for
1226commentary and workarounds.
4cee8e80 1227
9607fc9c
PP
1228=item Constant subroutine %s undefined
1229
be771a83
GS
1230(W misc) You undefined a subroutine which had previously been eligible
1231for inlining. See L<perlsub/"Constant Functions"> for commentary and
1232workarounds.
9607fc9c 1233
e7ea3e70
IZ
1234=item Copy method did not return a reference
1235
64977eb6 1236(F) The method which overloads "=" is buggy. See
13a2d996 1237L<overload/Copy Constructor>.
e7ea3e70 1238
6798c92b
GS
1239=item CORE::%s is not a keyword
1240
1241(F) The CORE:: namespace is reserved for Perl keywords.
1242
a0d0e21e
LW
1243=item corrupted regexp pointers
1244
1245(P) The regular expression engine got confused by what the regular
1246expression compiler gave it.
1247
1248=item corrupted regexp program
1249
be771a83
GS
1250(P) The regular expression engine got passed a regexp program without a
1251valid magic number.
a0d0e21e 1252
6df41af2
GS
1253=item Corrupt malloc ptr 0x%lx at 0x%lx
1254
1255(P) The malloc package that comes with Perl had an internal failure.
1256
1257=item C<-p> destination: %s
1258
1259(F) An error occurred during the implicit output invoked by the C<-p>
1260command-line switch. (This output goes to STDOUT unless you've
1261redirected it with select().)
1262
1263=item C<-T> and C<-B> not implemented on filehandles
1264
1265(F) Perl can't peek at the stdio buffer of filehandles when it doesn't
1266know about your kind of stdio. You'll have to use a filename instead.
1267
a0d0e21e
LW
1268=item Deep recursion on subroutine "%s"
1269
be771a83
GS
1270(W recursion) This subroutine has called itself (directly or indirectly)
1271100 times more than it has returned. This probably indicates an
1272infinite recursion, unless you're writing strange benchmark programs, in
1273which case it indicates something else.
a0d0e21e 1274
f10b0346 1275=item defined(@array) is deprecated
69794302 1276
be771a83
GS
1277(D deprecated) defined() is not usually useful on arrays because it
1278checks for an undefined I<scalar> value. If you want to see if the
64977eb6 1279array is empty, just use C<if (@array) { # not empty }> for example.
69794302 1280
f10b0346 1281=item defined(%hash) is deprecated
69794302 1282
be771a83
GS
1283(D deprecated) defined() is not usually useful on hashes because it
1284checks for an undefined I<scalar> value. If you want to see if the hash
64977eb6 1285is empty, just use C<if (%hash) { # not empty }> for example.
69794302 1286
62658f4d
PM
1287=item %s defines neither package nor VERSION--version check failed
1288
1289(F) You said something like "use Module 42" but in the Module file
1290there are neither package declarations nor a C<$VERSION>.
1291
fc36a67e
PP
1292=item Delimiter for here document is too long
1293
be771a83
GS
1294(F) In a here document construct like C<<<FOO>, the label C<FOO> is too
1295long for Perl to handle. You have to be seriously twisted to write code
1296that triggers this error.
fc36a67e 1297
3cdd684c
TP
1298=item Did not produce a valid header
1299
1300See Server error.
1301
6df41af2
GS
1302=item %s did not return a true value
1303
1304(F) A required (or used) file must return a true value to indicate that
1305it compiled correctly and ran its initialization code correctly. It's
1306traditional to end such a file with a "1;", though any true value would
1307do. See L<perlfunc/require>.
1308
cc507455 1309=item (Did you mean &%s instead?)
4633a7c4 1310
be771a83
GS
1311(W) You probably referred to an imported subroutine &FOO as $FOO or some
1312such.
4633a7c4 1313
cc507455 1314=item (Did you mean "local" instead of "our"?)
33633739 1315
be771a83
GS
1316(W misc) Remember that "our" does not localize the declared global
1317variable. You have declared it again in the same lexical scope, which
1318seems superfluous.
33633739 1319
cc507455 1320=item (Did you mean $ or @ instead of %?)
a0d0e21e 1321
be771a83
GS
1322(W) You probably said %hash{$key} when you meant $hash{$key} or
1323@hash{@keys}. On the other hand, maybe you just meant %hash and got
1324carried away.
748a9306 1325
7e1af8bc 1326=item Died
5f05dabc
PP
1327
1328(F) You passed die() an empty string (the equivalent of C<die "">) or
1329you called it with no args and both C<$@> and C<$_> were empty.
1330
3cdd684c
TP
1331=item Document contains no data
1332
1333See Server error.
1334
62658f4d
PM
1335=item %s does not define %s::VERSION--version check failed
1336
1337(F) You said something like "use Module 42" but the Module did not
1338define a C<$VERSION.>
1339
a0d0e21e
LW
1340=item Don't know how to handle magic of type '%s'
1341
1342(P) The internal handling of magical variables has been cursed.
1343
1344=item do_study: out of memory
1345
1346(P) This should have been caught by safemalloc() instead.
1347
6df41af2
GS
1348=item (Do you need to predeclare %s?)
1349
1350(S) This is an educated guess made in conjunction with the message "%s
1351found where operator expected". It often means a subroutine or module
1352name is being referenced that hasn't been declared yet. This may be
1353because of ordering problems in your file, or because of a missing
be771a83
GS
1354"sub", "package", "require", or "use" statement. If you're referencing
1355something that isn't defined yet, you don't actually have to define the
1356subroutine or package before the current location. You can use an empty
1357"sub foo;" or "package FOO;" to enter a "forward" declaration.
6df41af2 1358
ac206dc8
RGS
1359=item dump() better written as CORE::dump()
1360
1361(W misc) You used the obsolescent C<dump()> built-in function, without fully
1362qualifying it as C<CORE::dump()>. Maybe it's a typo. See L<perlfunc/dump>.
1363
a0d0e21e
LW
1364=item Duplicate free() ignored
1365
be771a83
GS
1366(S malloc) An internal routine called free() on something that had
1367already been freed.
a0d0e21e 1368
4633a7c4
LW
1369=item elseif should be elsif
1370
be771a83
GS
1371(S) There is no keyword "elseif" in Perl because Larry thinks it's ugly.
1372Your code will be interpreted as an attempt to call a method named
1373"elseif" for the class returned by the following block. This is
4633a7c4
LW
1374unlikely to be what you want.
1375
ab13f0c7
JH
1376=item Empty %s
1377
af6f566e
HS
1378(F) C<\p> and C<\P> are used to introduce a named Unicode property, as
1379described in L<perlunicode> and L<perlre>. You used C<\p> or C<\P> in
1380a regular expression without specifying the property name.
ab13f0c7 1381
85ab1d1d 1382=item entering effective %s failed
5ff3f7a4 1383
85ab1d1d 1384(F) While under the C<use filetest> pragma, switching the real and
5ff3f7a4
GS
1385effective uids or gids failed.
1386
748a9306
LW
1387=item Error converting file specification %s
1388
5f05dabc 1389(F) An error peculiar to VMS. Because Perl may have to deal with file
748a9306 1390specifications in either VMS or Unix syntax, it converts them to a
be771a83
GS
1391single form when it must operate on them directly. Either you've passed
1392an invalid file specification to Perl, or you've found a case the
1393conversion routines don't handle. Drat.
748a9306 1394
e4d48cc9
GS
1395=item %s: Eval-group in insecure regular expression
1396
be771a83
GS
1397(F) Perl detected tainted data when trying to compile a regular
1398expression that contains the C<(?{ ... })> zero-width assertion, which
1399is unsafe. See L<perlre/(?{ code })>, and L<perlsec>.
e4d48cc9 1400
e4d48cc9
GS
1401=item %s: Eval-group not allowed at run time
1402
be771a83
GS
1403(F) Perl tried to compile a regular expression containing the
1404C<(?{ ... })> zero-width assertion at run time, as it would when the
1405pattern contains interpolated values. Since that is a security risk, it
1406is not allowed. If you insist, you may still do this by explicitly
1407building the pattern from an interpolated string at run time and using
1408that in an eval(). See L<perlre/(?{ code })>.
e4d48cc9 1409
6df41af2
GS
1410=item %s: Eval-group not allowed, use re 'eval'
1411
be771a83
GS
1412(F) A regular expression contained the C<(?{ ... })> zero-width
1413assertion, but that construct is only allowed when the C<use re 'eval'>
1414pragma is in effect. See L<perlre/(?{ code })>.
6df41af2 1415
fc36a67e
PP
1416=item Excessively long <> operator
1417
1418(F) The contents of a <> operator may not exceed the maximum size of a
1419Perl identifier. If you're just trying to glob a long list of
1420filenames, try using the glob() operator, or put the filenames into a
1421variable and glob that.
1422
ed9aa3b7
SG
1423=item exec? I'm not *that* kind of operating system
1424
1425(F) The C<exec> function is not implemented in MacPerl. See L<perlport>.
1426
f86702cc 1427=item Execution of %s aborted due to compilation errors
a0d0e21e
LW
1428
1429(F) The final summary message when a Perl compilation fails.
1430
1431=item Exiting eval via %s
1432
be771a83
GS
1433(W exiting) You are exiting an eval by unconventional means, such as a
1434goto, or a loop control statement.
e476b1b5
GS
1435
1436=item Exiting format via %s
1437
be771a83
GS
1438(W exiting) You are exiting an eval by unconventional means, such as a
1439goto, or a loop control statement.
a0d0e21e 1440
0a753a76
PP
1441=item Exiting pseudo-block via %s
1442
be771a83
GS
1443(W exiting) You are exiting a rather special block construct (like a
1444sort block or subroutine) by unconventional means, such as a goto, or a
1445loop control statement. See L<perlfunc/sort>.
0a753a76 1446
a0d0e21e
LW
1447=item Exiting subroutine via %s
1448
be771a83
GS
1449(W exiting) You are exiting a subroutine by unconventional means, such
1450as a goto, or a loop control statement.
a0d0e21e
LW
1451
1452=item Exiting substitution via %s
1453
be771a83
GS
1454(W exiting) You are exiting a substitution by unconventional means, such
1455as a return, a goto, or a loop control statement.
a0d0e21e 1456
7b8d334a
GS
1457=item Explicit blessing to '' (assuming package main)
1458
be771a83
GS
1459(W misc) You are blessing a reference to a zero length string. This has
1460the effect of blessing the reference into the package main. This is
1461usually not what you want. Consider providing a default target package,
1462e.g. bless($ref, $p || 'MyPackage');
7b8d334a 1463
6df41af2
GS
1464=item %s: Expression syntax
1465
be771a83
GS
1466(A) You've accidentally run your script through B<csh> instead of Perl.
1467Check the #! line, or manually feed your script into Perl yourself.
6df41af2
GS
1468
1469=item %s failed--call queue aborted
1470
1471(F) An untrapped exception was raised while executing a CHECK, INIT, or
1472END subroutine. Processing of the remainder of the queue of such
1473routines has been prematurely ended.
1474
7253e4e3 1475=item False [] range "%s" in regex; marked by <-- HERE in m/%s/
73b437c8 1476
be771a83 1477(W regexp) A character class range must start and end at a literal
7253e4e3
RK
1478character, not another character class like C<\d> or C<[:alpha:]>. The "-"
1479in your false range is interpreted as a literal "-". Consider quoting the
1480"-", "\-". The <-- HERE shows in the regular expression about where the
1481problem was discovered. See L<perlre>.
73b437c8 1482
748a9306 1483=item Fatal VMS error at %s, line %d
a0d0e21e 1484
be771a83
GS
1485(P) An error peculiar to VMS. Something untoward happened in a VMS
1486system service or RTL routine; Perl's exit status should provide more
1487details. The filename in "at %s" and the line number in "line %d" tell
1488you which section of the Perl source code is distressed.
a0d0e21e
LW
1489
1490=item fcntl is not implemented
1491
1492(F) Your machine apparently doesn't implement fcntl(). What is this, a
1493PDP-11 or something?
1494
af8c498a 1495=item Filehandle %s opened only for input
a0d0e21e 1496
be771a83
GS
1497(W io) You tried to write on a read-only filehandle. If you intended it
1498to be a read-write filehandle, you needed to open it with "+<" or "+>"
1499or "+>>" instead of with "<" or nothing. If you intended only to write
1500the file, use ">" or ">>". See L<perlfunc/open>.
a0d0e21e 1501
af8c498a 1502=item Filehandle %s opened only for output
a0d0e21e 1503
be771a83
GS
1504(W io) You tried to read from a filehandle opened only for writing. If
1505you intended it to be a read/write filehandle, you needed to open it
1506with "+<" or "+>" or "+>>" instead of with "<" or nothing. If you
1507intended only to read from the file, use "<". See L<perlfunc/open>.
a0d0e21e
LW
1508
1509=item Final $ should be \$ or $name
1510
1511(F) You must now decide whether the final $ in a string was meant to be
be771a83
GS
1512a literal dollar sign, or was meant to introduce a variable name that
1513happens to be missing. So you have to put either the backslash or the
1514name.
a0d0e21e
LW
1515
1516=item Final @ should be \@ or @name
1517
1518(F) You must now decide whether the final @ in a string was meant to be
be771a83
GS
1519a literal "at" sign, or was meant to introduce a variable name that
1520happens to be missing. So you have to put either the backslash or the
1521name.
a0d0e21e 1522
56e90b21
GS
1523=item flock() on closed filehandle %s
1524
be771a83 1525(W closed) The filehandle you're attempting to flock() got itself closed
c289d2f7 1526some time before now. Check your control flow. flock() operates on
be771a83
GS
1527filehandles. Are you attempting to call flock() on a dirhandle by the
1528same name?
56e90b21 1529
5cd5c422
RB
1530=item Quantifier follows nothing in regex;
1531
1532marked by <-- HERE in m/%s/
6df41af2 1533
b45f050a 1534(F) You started a regular expression with a quantifier. Backslash it if you
7253e4e3
RK
1535meant it literally. The <-- HERE shows in the regular expression about
1536where the problem was discovered. See L<perlre>.
6df41af2
GS
1537
1538=item Format not terminated
1539
1540(F) A format must be terminated by a line with a solitary dot. Perl got
1541to the end of your file without finding such a line.
1542
a0d0e21e
LW
1543=item Format %s redefined
1544
e476b1b5 1545(W redefine) You redefined a format. To suppress this warning, say
a0d0e21e
LW
1546
1547 {
271595cc 1548 no warnings 'redefine';
a0d0e21e
LW
1549 eval "format NAME =...";
1550 }
1551
a0d0e21e
LW
1552=item Found = in conditional, should be ==
1553
e476b1b5 1554(W syntax) You said
a0d0e21e
LW
1555
1556 if ($foo = 123)
1557
1558when you meant
1559
1560 if ($foo == 123)
1561
1562(or something like that).
1563
6df41af2
GS
1564=item %s found where operator expected
1565
1566(S) The Perl lexer knows whether to expect a term or an operator. If it
be771a83
GS
1567sees what it knows to be a term when it was expecting to see an
1568operator, it gives you this warning. Usually it indicates that an
1569operator or delimiter was omitted, such as a semicolon.
6df41af2 1570
a0d0e21e
LW
1571=item gdbm store returned %d, errno %d, key "%s"
1572
1573(S) A warning from the GDBM_File extension that a store failed.
1574
1575=item gethostent not implemented
1576
1577(F) Your C library apparently doesn't implement gethostent(), probably
1578because if it did, it'd feel morally obligated to return every hostname
1579on the Internet.
1580
69282e91 1581=item get%sname() on closed socket %s
a0d0e21e 1582
be771a83
GS
1583(W closed) You tried to get a socket or peer socket name on a closed
1584socket. Did you forget to check the return value of your socket() call?
a0d0e21e 1585
748a9306
LW
1586=item getpwnam returned invalid UIC %#o for user "%s"
1587
1588(S) A warning peculiar to VMS. The call to C<sys$getuai> underlying the
1589C<getpwnam> operator returned an invalid UIC.
1590
6df41af2
GS
1591=item getsockopt() on closed socket %s
1592
be771a83
GS
1593(W closed) You tried to get a socket option on a closed socket. Did you
1594forget to check the return value of your socket() call? See
6df41af2
GS
1595L<perlfunc/getsockopt>.
1596
1597=item Global symbol "%s" requires explicit package name
1598
1599(F) You've said "use strict vars", which indicates that all variables
1600must either be lexically scoped (using "my"), declared beforehand using
1601"our", or explicitly qualified to say which package the global variable
1602is in (using "::").
1603
e476b1b5
GS
1604=item glob failed (%s)
1605
be771a83
GS
1606(W glob) Something went wrong with the external program(s) used for
1607C<glob> and C<< <*.c> >>. Usually, this means that you supplied a
1608C<glob> pattern that caused the external program to fail and exit with a
1609nonzero status. If the message indicates that the abnormal exit
1610resulted in a coredump, this may also mean that your csh (C shell) is
1611broken. If so, you should change all of the csh-related variables in
1612config.sh: If you have tcsh, make the variables refer to it as if it
1613were csh (e.g. C<full_csh='/usr/bin/tcsh'>); otherwise, make them all
1614empty (except that C<d_csh> should be C<'undef'>) so that Perl will
1615think csh is missing. In either case, after editing config.sh, run
75b44862 1616C<./Configure -S> and rebuild Perl.
e476b1b5 1617
a0d0e21e
LW
1618=item Glob not terminated
1619
1620(F) The lexer saw a left angle bracket in a place where it was expecting
be771a83
GS
1621a term, so it's looking for the corresponding right angle bracket, and
1622not finding it. Chances are you left some needed parentheses out
1623earlier in the line, and you really meant a "less than".
a0d0e21e 1624
6df41af2 1625=item Got an error from DosAllocMem
a0d0e21e 1626
6df41af2
GS
1627(P) An error peculiar to OS/2. Most probably you're using an obsolete
1628version of Perl, and this should not happen anyway.
a0d0e21e
LW
1629
1630=item goto must have label
1631
1632(F) Unlike with "next" or "last", you're not allowed to goto an
1633unspecified destination. See L<perlfunc/goto>.
1634
18529408
IZ
1635=item %s-group starts with a count
1636
1637(F) In pack/unpack a ()-group started with a count. A count is
1638supposed to follow something: a template character or a ()-group.
1639
6df41af2
GS
1640=item %s had compilation errors
1641
1642(F) The final summary message when a C<perl -c> fails.
1643
a0d0e21e
LW
1644=item Had to create %s unexpectedly
1645
be771a83
GS
1646(S internal) A routine asked for a symbol from a symbol table that ought
1647to have existed already, but for some reason it didn't, and had to be
1648created on an emergency basis to prevent a core dump.
a0d0e21e
LW
1649
1650=item Hash %%s missing the % in argument %d of %s()
1651
be771a83
GS
1652(D deprecated) Really old Perl let you omit the % on hash names in some
1653spots. This is now heavily deprecated.
a0d0e21e 1654
6df41af2
GS
1655=item %s has too many errors
1656
1657(F) The parser has given up trying to parse the program after 10 errors.
1658Further error messages would likely be uninformative.
1659
252aa082
JH
1660=item Hexadecimal number > 0xffffffff non-portable
1661
e476b1b5 1662(W portable) The hexadecimal number you specified is larger than 2**32-1
9e24b6e2
JH
1663(4294967295) and therefore non-portable between systems. See
1664L<perlport> for more on portability concerns.
252aa082 1665
8903cb82
PP
1666=item Identifier too long
1667
1668(F) Perl limits identifiers (names for variables, functions, etc.) to
fc36a67e 1669about 250 characters for simple names, and somewhat more for compound
be771a83
GS
1670names (like C<$A::B>). You've exceeded Perl's limits. Future versions
1671of Perl are likely to eliminate these arbitrary limitations.
8903cb82 1672
6df41af2 1673=item Illegal binary digit %s
f675dbe5 1674
6df41af2 1675(F) You used a digit other than 0 or 1 in a binary number.
f675dbe5 1676
6df41af2 1677=item Illegal binary digit %s ignored
a0d0e21e 1678
be771a83
GS
1679(W digit) You may have tried to use a digit other than 0 or 1 in a
1680binary number. Interpretation of the binary number stopped before the
1681offending digit.
a0d0e21e 1682
4fdae800
PP
1683=item Illegal character %s (carriage return)
1684
d5898338 1685(F) Perl normally treats carriage returns in the program text as it
be771a83
GS
1686would any other whitespace, which means you should never see this error
1687when Perl was built using standard options. For some reason, your
1688version of Perl appears to have been built without this support. Talk
1689to your Perl administrator.
4fdae800 1690
d37a9538
ST
1691=item Illegal character in prototype for %s : %s
1692
420cdfc1 1693(W syntax) An illegal character was found in a prototype declaration. Legal
d37a9538
ST
1694characters in prototypes are $, @, %, *, ;, [, ], &, and \.
1695
a0d0e21e
LW
1696=item Illegal division by zero
1697
be771a83
GS
1698(F) You tried to divide a number by 0. Either something was wrong in
1699your logic, or you need to put a conditional in to guard against
1700meaningless input.
a0d0e21e 1701
6df41af2
GS
1702=item Illegal hexadecimal digit %s ignored
1703
be771a83
GS
1704(W digit) You may have tried to use a character other than 0 - 9 or
1705A - F, a - f in a hexadecimal number. Interpretation of the hexadecimal
1706number stopped before the illegal character.
6df41af2 1707
a0d0e21e
LW
1708=item Illegal modulus zero
1709
be771a83
GS
1710(F) You tried to divide a number by 0 to get the remainder. Most
1711numbers don't take to this kindly.
a0d0e21e 1712
6df41af2 1713=item Illegal number of bits in vec
399388f4 1714
6df41af2
GS
1715(F) The number of bits in vec() (the third argument) must be a power of
1716two from 1 to 32 (or 64, if your platform supports that).
399388f4
GS
1717
1718=item Illegal octal digit %s
a0d0e21e 1719
d1be9408 1720(F) You used an 8 or 9 in an octal number.
a0d0e21e 1721
399388f4 1722=item Illegal octal digit %s ignored
748a9306 1723
d1be9408 1724(W digit) You may have tried to use an 8 or 9 in an octal number.
75b44862 1725Interpretation of the octal number stopped before the 8 or 9.
748a9306 1726
6df41af2 1727=item Illegal switch in PERL5OPT: %s
6ff81951 1728
6df41af2 1729(X) The PERL5OPT environment variable may only be used to set the
1c4db469 1730following switches: B<-[DIMUdmtw]>.
6ff81951 1731
6df41af2 1732=item Ill-formed CRTL environ value "%s"
81e118e0 1733
75b44862 1734(W internal) A warning peculiar to VMS. Perl tried to read the CRTL's
be771a83
GS
1735internal environ array, and encountered an element without the C<=>
1736delimiter used to separate keys from values. The element is ignored.
09bef843 1737
6df41af2 1738=item Ill-formed message in prime_env_iter: |%s|
54310121 1739
be771a83
GS
1740(W internal) A warning peculiar to VMS. Perl tried to read a logical
1741name or CLI symbol definition when preparing to iterate over %ENV, and
1742didn't see the expected delimiter between key and value, so the line was
1743ignored.
54310121 1744
6df41af2 1745=item (in cleanup) %s
9607fc9c 1746
be771a83
GS
1747(W misc) This prefix usually indicates that a DESTROY() method raised
1748the indicated exception. Since destructors are usually called by the
1749system at arbitrary points during execution, and often a vast number of
1750times, the warning is issued only once for any number of failures that
1751would otherwise result in the same message being repeated.
6df41af2 1752
be771a83
GS
1753Failure of user callbacks dispatched using the C<G_KEEPERR> flag could
1754also result in this warning. See L<perlcall/G_KEEPERR>.
9607fc9c 1755
979699d9
JH
1756=item In EBCDIC the v-string components cannot exceed 2147483647
1757
1758(F) An error peculiar to EBCDIC. Internally, v-strings are stored as
1759Unicode code points, and encoded in EBCDIC as UTF-EBCDIC. The UTF-EBCDIC
1760encoding is limited to code points no larger than 2147483647 (0x7FFFFFFF).
1761
a0d0e21e
LW
1762=item Insecure dependency in %s
1763
8b1a09fc 1764(F) You tried to do something that the tainting mechanism didn't like.
be771a83
GS
1765The tainting mechanism is turned on when you're running setuid or
1766setgid, or when you specify B<-T> to turn it on explicitly. The
1767tainting mechanism labels all data that's derived directly or indirectly
1768from the user, who is considered to be unworthy of your trust. If any
1769such data is used in a "dangerous" operation, you get this error. See
1770L<perlsec> for more information.
a0d0e21e
LW
1771
1772=item Insecure directory in %s
1773
be771a83
GS
1774(F) You can't use system(), exec(), or a piped open in a setuid or
1775setgid script if C<$ENV{PATH}> contains a directory that is writable by
1776the world. See L<perlsec>.
a0d0e21e 1777
62f468fc 1778=item Insecure $ENV{%s} while running %s
a0d0e21e
LW
1779
1780(F) You can't use system(), exec(), or a piped open in a setuid or
62f468fc
G
1781setgid script if any of C<$ENV{PATH}>, C<$ENV{IFS}>, C<$ENV{CDPATH}>,
1782C<$ENV{ENV}> or C<$ENV{BASH_ENV}> are derived from data supplied (or
a0d0e21e
LW
1783potentially supplied) by the user. The script must set the path to a
1784known value, using trustworthy data. See L<perlsec>.
1785
a7ae9550
GS
1786=item Integer overflow in %s number
1787
75b44862 1788(W overflow) The hexadecimal, octal or binary number you have specified
be771a83
GS
1789either as a literal or as an argument to hex() or oct() is too big for
1790your architecture, and has been converted to a floating point number.
1791On a 32-bit architecture the largest hexadecimal, octal or binary number
9e24b6e2
JH
1792representable without overflow is 0xFFFFFFFF, 037777777777, or
17930b11111111111111111111111111111111 respectively. Note that Perl
1794transparently promotes all numbers to a floating point representation
1795internally--subject to loss of precision errors in subsequent
1796operations.
bbce6d69 1797
7253e4e3 1798=item Internal disaster in regex; marked by <-- HERE in m/%s/
6df41af2
GS
1799
1800(P) Something went badly wrong in the regular expression parser.
7253e4e3 1801The <-- HERE shows in the regular expression about where the problem was
b45f050a
JF
1802discovered.
1803
748a9306
LW
1804=item Internal inconsistency in tracking vforks
1805
be771a83
GS
1806(S) A warning peculiar to VMS. Perl keeps track of the number of times
1807you've called C<fork> and C<exec>, to determine whether the current call
1808to C<exec> should affect the current script or a subprocess (see
1809L<perlvms/"exec LIST">). Somehow, this count has become scrambled, so
1810Perl is making a guess and treating this C<exec> as a request to
1811terminate the Perl script and execute the specified command.
748a9306 1812
7253e4e3 1813=item Internal urp in regex; marked by <-- HERE in m/%s/
b45f050a 1814
7253e4e3
RK
1815(P) Something went badly awry in the regular expression parser. The
1816<-- HERE shows in the regular expression about where the problem was
1817discovered.
a0d0e21e 1818
6df41af2
GS
1819=item %s (...) interpreted as function
1820
75b44862 1821(W syntax) You've run afoul of the rule that says that any list operator
be771a83 1822followed by parentheses turns into a function, with all the list
64977eb6 1823operators arguments found inside the parentheses. See
13a2d996 1824L<perlop/Terms and List Operators (Leftward)>.
6df41af2 1825
09bef843
SB
1826=item Invalid %s attribute: %s
1827
1828The indicated attribute for a subroutine or variable was not recognized
1829by Perl or by a user-supplied handler. See L<attributes>.
1830
1831=item Invalid %s attributes: %s
1832
be771a83
GS
1833The indicated attributes for a subroutine or variable were not
1834recognized by Perl or by a user-supplied handler. See L<attributes>.
09bef843 1835
c635e13b
PP
1836=item Invalid conversion in %s: "%s"
1837
be771a83
GS
1838(W printf) Perl does not understand the given format conversion. See
1839L<perlfunc/sprintf>.
c635e13b 1840
7253e4e3 1841=item Invalid [] range "%s" in regex; marked by <-- HERE in m/%s/
6df41af2
GS
1842
1843(F) The range specified in a character class had a minimum character
7253e4e3
RK
1844greater than the maximum character. One possibility is that you forgot the
1845C<{}> from your ending C<\x{}> - C<\x> without the curly braces can go only
1846up to C<ff>. The <-- HERE shows in the regular expression about where the
1847problem was discovered. See L<perlre>.
6df41af2 1848
7253e4e3 1849=item Invalid [] range "%s" in transliteration operator
c2e66d9e
GS
1850
1851(F) The range specified in the tr/// or y/// operator had a minimum
1852character greater than the maximum character. See L<perlop>.
1853
09bef843
SB
1854=item Invalid separator character %s in attribute list
1855
0120eecf 1856(F) Something other than a colon or whitespace was seen between the
be771a83
GS
1857elements of an attribute list. If the previous attribute had a
1858parenthesised parameter list, perhaps that list was terminated too soon.
1859See L<attributes>.
09bef843 1860
96e4d5b1
PP
1861=item Invalid type in pack: '%s'
1862
8903cb82 1863(F) The given character is not a valid pack type. See L<perlfunc/pack>.
be771a83
GS
1864(W pack) The given character is not a valid pack type but used to be
1865silently ignored.
96e4d5b1
PP
1866
1867=item Invalid type in unpack: '%s'
1868
be771a83
GS
1869(F) The given character is not a valid unpack type. See
1870L<perlfunc/unpack>.
75b44862
GS
1871(W unpack) The given character is not a valid unpack type but used to be
1872silently ignored.
96e4d5b1 1873
a0d0e21e
LW
1874=item ioctl is not implemented
1875
1876(F) Your machine apparently doesn't implement ioctl(), which is pretty
1877strange for a machine that supports C.
1878
c289d2f7
JH
1879=item ioctl() on unopened %s
1880
1881(W unopened) You tried ioctl() on a filehandle that was never opened.
1882Check you control flow and number of arguments.
1883
80cbd5ad
JH
1884=item IO::Socket::atmark not implemented on this architecture
1885
1886(F) Your machine doesn't implement the sockatmark() functionality,
1887neither as a system call or an ioctl call (SIOCATMARK).
1888
6ad11d81
JH
1889=item `%s' is not a code reference
1890
04a80ee0
RGS
1891(W overload) The second (fourth, sixth, ...) argument of overload::constant
1892needs to be a code reference. Either an anonymous subroutine, or a reference
6ad11d81
JH
1893to a subroutine.
1894
1895=item `%s' is not an overloadable type
1896
04a80ee0
RGS
1897(W overload) You tried to overload a constant type the overload package is
1898unaware of.
6ad11d81 1899
a0d0e21e
LW
1900=item junk on end of regexp
1901
1902(P) The regular expression parser is confused.
1903
1904=item Label not found for "last %s"
1905
be771a83
GS
1906(F) You named a loop to break out of, but you're not currently in a loop
1907of that name, not even if you count where you were called from. See
1908L<perlfunc/last>.
a0d0e21e
LW
1909
1910=item Label not found for "next %s"
1911
1912(F) You named a loop to continue, but you're not currently in a loop of
1913that name, not even if you count where you were called from. See
1914L<perlfunc/last>.
1915
1916=item Label not found for "redo %s"
1917
1918(F) You named a loop to restart, but you're not currently in a loop of
1919that name, not even if you count where you were called from. See
1920L<perlfunc/last>.
1921
85ab1d1d 1922=item leaving effective %s failed
5ff3f7a4 1923
85ab1d1d 1924(F) While under the C<use filetest> pragma, switching the real and
5ff3f7a4
GS
1925effective uids or gids failed.
1926
69282e91 1927=item listen() on closed socket %s
a0d0e21e 1928
be771a83
GS
1929(W closed) You tried to do a listen on a closed socket. Did you forget
1930to check the return value of your socket() call? See
1931L<perlfunc/listen>.
a0d0e21e 1932
5d3e98de
RGS
1933=item lstat() on filehandle %s
1934
1935(W io) You tried to do an lstat on a filehandle. What did you mean
1936by that? lstat() makes sense only on filenames. (Perl did a fstat()
1937instead on the filehandle.)
1938
cd06dffe
GS
1939=item Lvalue subs returning %s not implemented yet
1940
1941(F) Due to limitations in the current implementation, array and hash
be771a83
GS
1942values cannot be returned in subroutines used in lvalue context. See
1943L<perlsub/"Lvalue subroutines">.
cd06dffe 1944
5cd5c422
RB
1945=item Lookbehind longer than %d not implemented in regex;
1946
1947marked by <-- HERE in m/%s/
b45f050a
JF
1948
1949(F) There is currently a limit on the length of string which lookbehind can
7253e4e3
RK
1950handle. This restriction may be eased in a future release. The <-- HERE
1951shows in the regular expression about where the problem was discovered.
2e50fd82 1952
6df41af2
GS
1953=item Malformed PERLLIB_PREFIX
1954
1955(F) An error peculiar to OS/2. PERLLIB_PREFIX should be of the form
1956
1957 prefix1;prefix2
1958
1959or
6df41af2
GS
1960 prefix1 prefix2
1961
be771a83
GS
1962with nonempty prefix1 and prefix2. If C<prefix1> is indeed a prefix of
1963a builtin library search path, prefix2 is substituted. The error may
1964appear if components are not found, or are too long. See
fecfaeb8 1965"PERLLIB_PREFIX" in L<perlos2>.
6df41af2 1966
2f758a16
ST
1967=item Malformed prototype for %s: %s
1968
d37a9538
ST
1969(F) You tried to use a function with a malformed prototype. The
1970syntax of function prototypes is given a brief compile-time check for
1971obvious errors like invalid characters. A more rigorous check is run
1972when the function is called.
2f758a16 1973
ba210ebe
JH
1974=item Malformed UTF-8 character (%s)
1975
1976Perl detected something that didn't comply with UTF-8 encoding rules.
1977
901b21bf
JH
1978One possible cause is that you read in data that you thought to be in
1979UTF-8 but it wasn't (it was for example legacy 8-bit data). Another
1980possibility is careless use of utf8::upgrade().
1981
dea0fc0b
JH
1982=item Malformed UTF-16 surrogate
1983
1984Perl thought it was reading UTF-16 encoded character data but while
1985doing it Perl met a malformed Unicode surrogate.
1986
5cd5c422
RB
1987=item %s matches null string many times in regex;
1988
1989marked by <-- HERE in m/%s/
6df41af2
GS
1990
1991(W regexp) The pattern you've specified would be an infinite loop if the
7253e4e3
RK
1992regular expression engine didn't specifically check for that. The <-- HERE
1993shows in the regular expression about where the problem was discovered.
1994See L<perlre>.
6df41af2 1995
25f58aea
PN
1996=item "%s" may clash with future reserved word
1997
1998(W) This warning may be due to running a perl5 script through a perl4
1999interpreter, especially if the word that is being warned about is
2000"use" or "my".
2001
6df41af2
GS
2002=item % may only be used in unpack
2003
2004(F) You can't pack a string by supplying a checksum, because the
be771a83
GS
2005checksumming process loses information, and you can't go the other way.
2006See L<perlfunc/unpack>.
6df41af2 2007
a0d0e21e
LW
2008=item Method for operation %s not found in package %s during blessing
2009
2010(F) An attempt was made to specify an entry in an overloading table that
e7ea3e70 2011doesn't resolve to a valid subroutine. See L<overload>.
a0d0e21e 2012
3cdd684c
TP
2013=item Method %s not permitted
2014
2015See Server error.
2016
a0d0e21e
LW
2017=item Might be a runaway multi-line %s string starting on line %d
2018
2019(S) An advisory indicating that the previous error may have been caused
2020by a missing delimiter on a string or pattern, because it eventually
2021ended earlier on the current line.
2022
2023=item Misplaced _ in number
2024
d4ced10d
JH
2025(W syntax) An underscore (underbar) in a numeric constant did not
2026separate two digits.
a0d0e21e 2027
4a2d328f 2028=item Missing %sbrace%s on \N{}
423cee85 2029
4a2d328f 2030(F) Wrong syntax of character name literal C<\N{charname}> within
423cee85
JH
2031double-quotish context.
2032
a0d0e21e
LW
2033=item Missing comma after first argument to %s function
2034
2035(F) While certain functions allow you to specify a filehandle or an
2036"indirect object" before the argument list, this ain't one of them.
2037
06eaf0bc
GS
2038=item Missing command in piped open
2039
be771a83
GS
2040(W pipe) You used the C<open(FH, "| command")> or
2041C<open(FH, "command |")> construction, but the command was missing or
2042blank.
06eaf0bc 2043
6df41af2
GS
2044=item Missing name in "my sub"
2045
be771a83
GS
2046(F) The reserved syntax for lexically scoped subroutines requires that
2047they have a name with which they can be found.
6df41af2
GS
2048
2049=item Missing $ on loop variable
2050
be771a83
GS
2051(F) Apparently you've been programming in B<csh> too much. Variables
2052are always mentioned with the $ in Perl, unlike in the shells, where it
2053can vary from one line to the next.
6df41af2 2054
cc507455 2055=item (Missing operator before %s?)
748a9306
LW
2056
2057(S) This is an educated guess made in conjunction with the message "%s
2058found where operator expected". Often the missing operator is a comma.
2059
ab13f0c7
JH
2060=item Missing right brace on %s
2061
2062(F) Missing right brace in C<\p{...}> or C<\P{...}>.
2063
d98d5fff 2064=item Missing right curly or square bracket
a0d0e21e 2065
be771a83
GS
2066(F) The lexer counted more opening curly or square brackets than closing
2067ones. As a general rule, you'll find it's missing near the place you
2068were last editing.
a0d0e21e 2069
6df41af2
GS
2070=item (Missing semicolon on previous line?)
2071
2072(S) This is an educated guess made in conjunction with the message "%s
2073found where operator expected". Don't automatically put a semicolon on
2074the previous line just because you saw this message.
2075
a0d0e21e
LW
2076=item Modification of a read-only value attempted
2077
2078(F) You tried, directly or indirectly, to change the value of a
5f05dabc 2079constant. You didn't, of course, try "2 = 1", because the compiler
a0d0e21e
LW
2080catches that. But an easy way to do the same thing is:
2081
2082 sub mod { $_[0] = 1 }
2083 mod(2);
2084
2085Another way is to assign to a substr() that's off the end of the string.
2086
c5674021
PDF
2087Yet another way is to assign to a C<foreach> loop I<VAR> when I<VAR>
2088is aliased to a constant in the look I<LIST>:
2089
2090 $x = 1;
2091 foreach my $n ($x, 2) {
2092 $n *= 2; # modifies the $x, but fails on attempt to modify the 2
64977eb6 2093 }
c5674021 2094
7a4340ed 2095=item Modification of non-creatable array value attempted, %s
a0d0e21e
LW
2096
2097(F) You tried to make an array value spring into existence, and the
2098subscript was probably negative, even counting from end of the array
2099backwards.
2100
7a4340ed 2101=item Modification of non-creatable hash value attempted, %s
a0d0e21e 2102
be771a83
GS
2103(P) You tried to make a hash value spring into existence, and it
2104couldn't be created for some peculiar reason.
a0d0e21e
LW
2105
2106=item Module name must be constant
2107
2108(F) Only a bare module name is allowed as the first argument to a "use".
2109
be98fb35 2110=item Module name required with -%c option
6df41af2 2111
be98fb35
GS
2112(F) The C<-M> or C<-m> options say that Perl should load some module, but
2113you omitted the name of the module. Consult L<perlrun> for full details
2114about C<-M> and C<-m>.
6df41af2 2115
ed9aa3b7
SG
2116=item More than one argument to open
2117
2118(F) The C<open> function has been asked to open multiple files. This
2119can happen if you are trying to open a pipe to a command that takes a
2120list of arguments, but have forgotten to specify a piped open mode.
2121See L<perlfunc/open> for details.
2122
a0d0e21e
LW
2123=item msg%s not implemented
2124
2125(F) You don't have System V message IPC on your system.
2126
2127=item Multidimensional syntax %s not supported
2128
75b44862
GS
2129(W syntax) Multidimensional arrays aren't written like C<$foo[1,2,3]>.
2130They're written like C<$foo[1][2][3]>, as in C.
8b1a09fc 2131
6df41af2 2132=item / must be followed by a*, A* or Z*
09bef843 2133
6df41af2 2134(F) You had a pack template indicating a counted-length string,
be771a83
GS
2135Currently the only things that can have their length counted are a*, A*
2136or Z*. See L<perlfunc/pack>.
6df41af2
GS
2137
2138=item / must be followed by a, A or Z
2139
be771a83
GS
2140(F) You had an unpack template indicating a counted-length string, which
2141must be followed by one of the letters a, A or Z to indicate what sort
2142of string is to be unpacked. See L<perlfunc/pack>.
6df41af2
GS
2143
2144=item / must follow a numeric type
2145
be771a83
GS
2146(F) You had an unpack template that contained a '#', but this did not
2147follow some numeric unpack specification. See L<perlfunc/pack>.
6df41af2
GS
2148
2149=item "my sub" not yet implemented
2150
be771a83
GS
2151(F) Lexically scoped subroutines are not yet implemented. Don't try
2152that yet.
6df41af2
GS
2153
2154=item "my" variable %s can't be in a package
2155
be771a83
GS
2156(F) Lexically scoped variables aren't in a package, so it doesn't make
2157sense to try to declare one with a package qualifier on the front. Use
2158local() if you want to localize a package variable.
09bef843 2159
8b1a09fc
PP
2160=item Name "%s::%s" used only once: possible typo
2161
e476b1b5 2162(W once) Typographical errors often show up as unique variable names.
be771a83
GS
2163If you had a good reason for having a unique name, then just mention it
2164again somehow to suppress the message. The C<our> declaration is
77ca0c92 2165provided for this purpose.
a0d0e21e
LW
2166
2167=item Negative length
2168
be771a83
GS
2169(F) You tried to do a read/write/send/recv operation with a buffer
2170length that is less than 0. This is difficult to imagine.
a0d0e21e 2171
ed9aa3b7
SG
2172=item Negative offset to vec in lvalue context
2173
2174(F) When C<vec> is called in an lvalue context, the second argument must be
2175greater than or equal to zero.
2176
7253e4e3 2177=item Nested quantifiers in regex; marked by <-- HERE in m/%s/
a0d0e21e 2178
b45f050a 2179(F) You can't quantify a quantifier without intervening parentheses. So
7253e4e3 2180things like ** or +* or ?* are illegal. The <-- HERE shows in the regular
b45f050a 2181expression about where the problem was discovered.
a0d0e21e 2182
7253e4e3 2183Note that the minimal matching quantifiers, C<*?>, C<+?>, and
be771a83 2184C<??> appear to be nested quantifiers, but aren't. See L<perlre>.
a0d0e21e 2185
6df41af2 2186=item %s never introduced
a0d0e21e 2187
be771a83
GS
2188(S internal) The symbol in question was declared but somehow went out of
2189scope before it could possibly have been used.
a0d0e21e
LW
2190
2191=item No %s allowed while running setuid
2192
be771a83
GS
2193(F) Certain operations are deemed to be too insecure for a setuid or
2194setgid script to even be allowed to attempt. Generally speaking there
2195will be another way to do what you want that is, if not secure, at least
2196securable. See L<perlsec>.
a0d0e21e
LW
2197
2198=item No B<-e> allowed in setuid scripts
2199
2200(F) A setuid script can't be specified by the user.
2201
2202=item No comma allowed after %s
2203
2204(F) A list operator that has a filehandle or "indirect object" is not
2205allowed to have a comma between that and the following arguments.
2206Otherwise it'd be just another one of the arguments.
2207
0a753a76
PP
2208One possible cause for this is that you expected to have imported a
2209constant to your name space with B<use> or B<import> while no such
2210importing took place, it may for example be that your operating system
2211does not support that particular constant. Hopefully you did use an
2212explicit import list for the constants you expect to see, please see
2213L<perlfunc/use> and L<perlfunc/import>. While an explicit import list
2214would probably have caught this error earlier it naturally does not
2215remedy the fact that your operating system still does not support that
2216constant. Maybe you have a typo in the constants of the symbol import
2217list of B<use> or B<import> or in the constant name at the line where
2218this error was triggered?
2219
748a9306
LW
2220=item No command into which to pipe on command line
2221
be771a83
GS
2222(F) An error peculiar to VMS. Perl handles its own command line
2223redirection, and found a '|' at the end of the command line, so it
2224doesn't know where you want to pipe the output from this command.
748a9306 2225
a0d0e21e
LW
2226=item No DB::DB routine defined
2227
be771a83
GS
2228(F) The currently executing code was compiled with the B<-d> switch, but
2229for some reason the perl5db.pl file (or some facsimile thereof) didn't
2230define a routine to be called at the beginning of each statement. Which
2231is odd, because the file should have been required automatically, and
2232should have blown up the require if it didn't parse right.
a0d0e21e
LW
2233
2234=item No dbm on this machine
2235
2236(P) This is counted as an internal error, because every machine should
5f05dabc 2237supply dbm nowadays, because Perl comes with SDBM. See L<SDBM_File>.
a0d0e21e
LW
2238
2239=item No DBsub routine
2240
2241(F) The currently executing code was compiled with the B<-d> switch,
2242but for some reason the perl5db.pl file (or some facsimile thereof)
2243didn't define a DB::sub routine to be called at the beginning of each
2244ordinary subroutine call.
2245
c47ff5f1 2246=item No error file after 2> or 2>> on command line
748a9306 2247
be771a83
GS
2248(F) An error peculiar to VMS. Perl handles its own command line
2249redirection, and found a '2>' or a '2>>' on the command line, but can't
2250find the name of the file to which to write data destined for stderr.
748a9306 2251
c47ff5f1 2252=item No input file after < on command line
748a9306 2253
be771a83
GS
2254(F) An error peculiar to VMS. Perl handles its own command line
2255redirection, and found a '<' on the command line, but can't find the
2256name of the file from which to read data for stdin.
748a9306 2257
6df41af2
GS
2258=item No #! line
2259
2260(F) The setuid emulator requires that scripts have a well-formed #! line
2261even on machines that don't support the #! construct.
2262
2263=item "no" not allowed in expression
2264
be771a83
GS
2265(F) The "no" keyword is recognized and executed at compile time, and
2266returns no useful value. See L<perlmod>.
6df41af2 2267
c47ff5f1 2268=item No output file after > on command line
748a9306 2269
be771a83
GS
2270(F) An error peculiar to VMS. Perl handles its own command line
2271redirection, and found a lone '>' at the end of the command line, so it
2272doesn't know where you wanted to redirect stdout.
748a9306 2273
c47ff5f1 2274=item No output file after > or >> on command line
748a9306 2275
be771a83
GS
2276(F) An error peculiar to VMS. Perl handles its own command line
2277redirection, and found a '>' or a '>>' on the command line, but can't
2278find the name of the file to which to write data destined for stdout.
748a9306 2279
1ec3e8de
GS
2280=item No package name allowed for variable %s in "our"
2281
be771a83
GS
2282(F) Fully qualified variable names are not allowed in "our"
2283declarations, because that doesn't make much sense under existing
2284semantics. Such syntax is reserved for future extensions.
1ec3e8de 2285
a0d0e21e
LW
2286=item No Perl script found in input
2287
2288(F) You called C<perl -x>, but no line was found in the file beginning
2289with #! and containing the word "perl".
2290
2291=item No setregid available
2292
2293(F) Configure didn't find anything resembling the setregid() call for
2294your system.
2295
2296=item No setreuid available
2297
2298(F) Configure didn't find anything resembling the setreuid() call for
2299your system.
2300
a67e862a 2301=item No space allowed after -%c
a0d0e21e 2302
be771a83
GS
2303(F) The argument to the indicated command line switch must follow
2304immediately after the switch, without intervening spaces.
a0d0e21e 2305
6df41af2
GS
2306=item No %s specified for -%c
2307
2308(F) The indicated command line switch needs a mandatory argument, but
2309you haven't specified one.
2310
2c692339
RGS
2311=item No such class %s
2312
2313(F) You provided a class qualifier in a "my" or "our" declaration, but
2314this class doesn't exist at this point in your program.
2315
6df41af2
GS
2316=item No such pipe open
2317
2318(P) An error peculiar to VMS. The internal routine my_pclose() tried to
be771a83
GS
2319close a pipe which hadn't been opened. This should have been caught
2320earlier as an attempt to close an unopened filehandle.
6df41af2 2321
88e9b055 2322=item No such pseudo-hash field "%s"
57079c46 2323
88e9b055 2324(F) You tried to access an array as a hash, but the field name used is
57079c46
GA
2325not defined. The hash at index 0 should map all valid field names to
2326array indices for that to work.
2327
88e9b055 2328=item No such pseudo-hash field "%s" in variable %s of type %s
f1192cee 2329
be771a83
GS
2330(F) You tried to access a field of a typed variable where the type does
2331not know about the field name. The field names are looked up in the
2332%FIELDS hash in the type package at compile time. The %FIELDS hash is
2333%usually set up with the 'fields' pragma.
f1192cee 2334
a0d0e21e
LW
2335=item No such signal: SIG%s
2336
be771a83
GS
2337(W signal) You specified a signal name as a subscript to %SIG that was
2338not recognized. Say C<kill -l> in your shell to see the valid signal
2339names on your system.
a0d0e21e
LW
2340
2341=item Not a CODE reference
2342
2343(F) Perl was trying to evaluate a reference to a code value (that is, a
2344subroutine), but found a reference to something else instead. You can
be771a83
GS
2345use the ref() function to find out what kind of ref it really was. See
2346also L<perlref>.
a0d0e21e
LW
2347
2348=item Not a format reference
2349
2350(F) I'm not sure how you managed to generate a reference to an anonymous
2351format, but this indicates you did, and that it didn't exist.
2352
2353=item Not a GLOB reference
2354
be771a83
GS
2355(F) Perl was trying to evaluate a reference to a "typeglob" (that is, a
2356symbol table entry that looks like C<*foo>), but found a reference to
2357something else instead. You can use the ref() function to find out what
2358kind of ref it really was. See L<perlref>.
a0d0e21e
LW
2359
2360=item Not a HASH reference
2361
be771a83
GS
2362(F) Perl was trying to evaluate a reference to a hash value, but found a
2363reference to something else instead. You can use the ref() function to
2364find out what kind of ref it really was. See L<perlref>.
a0d0e21e 2365
6df41af2
GS
2366=item Not an ARRAY reference
2367
be771a83
GS
2368(F) Perl was trying to evaluate a reference to an array value, but found
2369a reference to something else instead. You can use the ref() function
2370to find out what kind of ref it really was. See L<perlref>.
6df41af2 2371
a0d0e21e
LW
2372=item Not a perl script
2373
2374(F) The setuid emulator requires that scripts have a well-formed #! line
2375even on machines that don't support the #! construct. The line must
2376mention perl.
2377
2378=item Not a SCALAR reference
2379
be771a83
GS
2380(F) Perl was trying to evaluate a reference to a scalar value, but found
2381a reference to something else instead. You can use the ref() function
2382to find out what kind of ref it really was. See L<perlref>.
a0d0e21e
LW
2383
2384=item Not a subroutine reference
2385
2386(F) Perl was trying to evaluate a reference to a code value (that is, a
2387subroutine), but found a reference to something else instead. You can
be771a83
GS
2388use the ref() function to find out what kind of ref it really was. See
2389also L<perlref>.
a0d0e21e 2390
e7ea3e70 2391=item Not a subroutine reference in overload table
a0d0e21e
LW
2392
2393(F) An attempt was made to specify an entry in an overloading table that
8b1a09fc 2394doesn't somehow point to a valid subroutine. See L<overload>.
a0d0e21e 2395
a0d0e21e
LW
2396=item Not enough arguments for %s
2397
2398(F) The function requires more arguments than you specified.
2399
6df41af2
GS
2400=item Not enough format arguments
2401
be771a83
GS
2402(W syntax) A format specified more picture fields than the next line
2403supplied. See L<perlform>.
6df41af2
GS
2404
2405=item %s: not found
2406
be771a83
GS
2407(A) You've accidentally run your script through the Bourne shell instead
2408of Perl. Check the #! line, or manually feed your script into Perl
2409yourself.
6df41af2 2410
206947d2
IZ
2411=item %s not allowed in length fields
2412
2413(F) The count in the (un)pack template may be replaced by C<[TEMPLATE]> only if
2414C<TEMPLATE> always matches the same amount of packed bytes. Redesign
2415the template.
2416
6df41af2 2417=item no UTC offset information; assuming local time is UTC
a0d0e21e 2418
6df41af2
GS
2419(S) A warning peculiar to VMS. Perl was unable to find the local
2420timezone offset, so it's assuming that local system time is equivalent
be771a83
GS
2421to UTC. If it's not, define the logical name
2422F<SYS$TIMEZONE_DIFFERENTIAL> to translate to the number of seconds which
2423need to be added to UTC to get local time.
a0d0e21e
LW
2424
2425=item Null filename used
2426
be771a83
GS
2427(F) You can't require the null filename, especially because on many
2428machines that means the current directory! See L<perlfunc/require>.
a0d0e21e 2429
6df41af2
GS
2430=item NULL OP IN RUN
2431
be771a83
GS
2432(P debugging) Some internal routine called run() with a null opcode
2433pointer.
6df41af2 2434
55497cff
PP
2435=item Null picture in formline
2436
2437(F) The first argument to formline must be a valid format picture
2438specification. It was found to be empty, which probably means you
2439supplied it an uninitialized value. See L<perlform>.
2440
a0d0e21e
LW
2441=item Null realloc
2442
2443(P) An attempt was made to realloc NULL.
2444
2445=item NULL regexp argument
2446
5f05dabc 2447(P) The internal pattern matching routines blew it big time.
a0d0e21e
LW
2448
2449=item NULL regexp parameter
2450
2451(P) The internal pattern matching routines are out of their gourd.
2452
fc36a67e
PP
2453=item Number too long
2454
be771a83 2455(F) Perl limits the representation of decimal numbers in programs to
da75cd15 2456about 250 characters. You've exceeded that length. Future
be771a83
GS
2457versions of Perl are likely to eliminate this arbitrary limitation. In
2458the meantime, try using scientific notation (e.g. "1e6" instead of
2459"1_000_000").
fc36a67e 2460
6df41af2
GS
2461=item Octal number in vector unsupported
2462
be771a83
GS
2463(F) Numbers with a leading C<0> are not currently allowed in vectors.
2464The octal number interpretation of such numbers may be supported in a
2465future version.
6df41af2 2466
252aa082
JH
2467=item Octal number > 037777777777 non-portable
2468
75b44862 2469(W portable) The octal number you specified is larger than 2**32-1
be771a83
GS
2470(4294967295) and therefore non-portable between systems. See
2471L<perlport> for more on portability concerns.
252aa082
JH
2472
2473See also L<perlport> for writing portable code.
2474
6ad11d81
JH
2475=item Odd number of arguments for overload::constant
2476
04a80ee0
RGS
2477(W overload) The call to overload::constant contained an odd number of
2478arguments. The arguments should come in pairs.
6ad11d81 2479
b21befc1
MG
2480=item Odd number of elements in anonymous hash
2481
2482(W misc) You specified an odd number of elements to initialize a hash,
2483which is odd, because hashes come in key/value pairs.
2484
1930e939 2485=item Odd number of elements in hash assignment
a0d0e21e 2486
be771a83
GS
2487(W misc) You specified an odd number of elements to initialize a hash,
2488which is odd, because hashes come in key/value pairs.
a0d0e21e 2489
bbce6d69
PP
2490=item Offset outside string
2491
2492(F) You tried to do a read/write/send/recv operation with an offset
be771a83
GS
2493pointing outside the buffer. This is difficult to imagine. The sole
2494exception to this is that C<sysread()>ing past the buffer will extend
2495the buffer and zero pad the new area.
bbce6d69 2496
9ddeeac9
JH
2497=item -%s on unopened filehandle %s
2498
2499(W unopened) You tried to invoke a file test operator on a filehandle
c289d2f7 2500that isn't open. Check your control flow. See also L<perlfunc/-X>.
9ddeeac9 2501
c289d2f7 2502=item %s() on unopened %s
2dd78f96
JH
2503
2504(W unopened) An I/O operation was attempted on a filehandle that was
2505never initialized. You need to do an open(), a sysopen(), or a socket()
2506call, or call a constructor from the FileHandle package.
2507
a0d0e21e
LW
2508=item oops: oopsAV
2509
e476b1b5 2510(S internal) An internal warning that the grammar is screwed up.
a0d0e21e
LW
2511
2512=item oops: oopsHV
2513
e476b1b5 2514(S internal) An internal warning that the grammar is screwed up.
a0d0e21e 2515
56f7f34b 2516=item Operation `%s': no method found, %s
44a8e56a 2517
be771a83
GS
2518(F) An attempt was made to perform an overloaded operation for which no
2519handler was defined. While some handlers can be autogenerated in terms
2520of other handlers, there is no default handler for any operation, unless
2521C<fallback> overloading key is specified to be true. See L<overload>.
44a8e56a 2522
748a9306
LW
2523=item Operator or semicolon missing before %s
2524
be771a83
GS
2525(S ambiguous) You used a variable or subroutine call where the parser
2526was expecting an operator. The parser has assumed you really meant to
2527use an operator, but this is highly likely to be incorrect. For
2528example, if you say "*foo *foo" it will be interpreted as if you said
2529"*foo * 'foo'".
748a9306 2530
6df41af2
GS
2531=item "our" variable %s redeclared
2532
be771a83
GS
2533(W misc) You seem to have already declared the same global once before
2534in the current lexical scope.
6df41af2 2535
a80b8354
GS
2536=item Out of memory!
2537
2538(X) The malloc() function returned 0, indicating there was insufficient
be771a83
GS
2539remaining memory (or virtual memory) to satisfy the request. Perl has
2540no option but to exit immediately.
a80b8354 2541
6df41af2 2542=item Out of memory during "large" request for %s
a0d0e21e 2543
6df41af2
GS
2544(F) The malloc() function returned 0, indicating there was insufficient
2545remaining memory (or virtual memory) to satisfy the request. However,
be771a83
GS
2546the request was judged large enough (compile-time default is 64K), so a
2547possibility to shut down by trapping this error is granted.
a0d0e21e 2548
1b979e0a 2549=item Out of memory during request for %s
a0d0e21e 2550
be771a83
GS
2551(X|F) The malloc() function returned 0, indicating there was
2552insufficient remaining memory (or virtual memory) to satisfy the
2553request.
eff9c6e2
CS
2554
2555The request was judged to be small, so the possibility to trap it
2556depends on the way perl was compiled. By default it is not trappable.
be771a83
GS
2557However, if compiled for this, Perl may use the contents of C<$^M> as an
2558emergency pool after die()ing with this message. In this case the error
b022d2d2
IZ
2559is trappable I<once>, and the error message will include the line and file
2560where the failed request happened.
55497cff 2561
1b979e0a
IZ
2562=item Out of memory during ridiculously large request
2563
2564(F) You can't allocate more than 2^31+"small amount" bytes. This error
be771a83
GS
2565is most likely to be caused by a typo in the Perl program. e.g.,
2566C<$arr[time]> instead of C<$arr[$time]>.
1b979e0a 2567
6df41af2
GS
2568=item Out of memory for yacc stack
2569
be771a83
GS
2570(F) The yacc parser wanted to grow its stack so it could continue
2571parsing, but realloc() wouldn't give it more memory, virtual or
2572otherwise.
6df41af2
GS
2573
2574=item @ outside of string
2575
2576(F) You had a pack template that specified an absolute position outside
2577the string being unpacked. See L<perlfunc/pack>.
2578
2579=item %s package attribute may clash with future reserved word: %s
2580
be771a83
GS
2581(W reserved) A lowercase attribute name was used that had a
2582package-specific handler. That name might have a meaning to Perl itself
2583some day, even though it doesn't yet. Perhaps you should use a
2584mixed-case attribute name, instead. See L<attributes>.
6df41af2 2585
a0d0e21e
LW
2586=item page overflow
2587
be771a83
GS
2588(W io) A single call to write() produced more lines than can fit on a
2589page. See L<perlform>.
a0d0e21e 2590
6df41af2
GS
2591=item panic: %s
2592
2593(P) An internal error.
2594
a0d0e21e
LW
2595=item panic: ck_grep
2596
2597(P) Failed an internal consistency check trying to compile a grep.
2598
2599=item panic: ck_split
2600
2601(P) Failed an internal consistency check trying to compile a split.
2602
2603=item panic: corrupt saved stack index
2604
be771a83
GS
2605(P) The savestack was requested to restore more localized values than
2606there are in the savestack.
a0d0e21e 2607
810b8aa5
GS
2608=item panic: del_backref
2609
2610(P) Failed an internal consistency check while trying to reset a weak
2611reference.
2612
a0d0e21e
LW
2613=item panic: die %s
2614
2615(P) We popped the context stack to an eval context, and then discovered
2616it wasn't an eval context.
2617
290deeac 2618=item panic: pp_match%s
a0d0e21e 2619
be771a83
GS
2620(P) The internal pp_match() routine was called with invalid operational
2621data.
a0d0e21e 2622
a0d0e21e
LW
2623=item panic: do_subst
2624
be771a83
GS
2625(P) The internal pp_subst() routine was called with invalid operational
2626data.
a0d0e21e 2627
2269b42e 2628=item panic: do_trans_%s
a0d0e21e 2629
2269b42e 2630(P) The internal do_trans routines were called with invalid operational
be771a83 2631data.
a0d0e21e 2632
c635e13b
PP
2633=item panic: frexp
2634
2635(P) The library function frexp() failed, making printf("%f") impossible.
2636
a0d0e21e
LW
2637=item panic: goto
2638
2639(P) We popped the context stack to a context with the specified label,
2640and then discovered it wasn't a context we know how to do a goto in.
2641
2642=item panic: INTERPCASEMOD
2643
2644(P) The lexer got into a bad state at a case modifier.
2645
2646=item panic: INTERPCONCAT
2647
2648(P) The lexer got into a bad state parsing a string with brackets.
2649
e446cec8
IZ
2650=item panic: kid popen errno read
2651
2652(F) forked child returned an incomprehensible message about its errno.
2653
a0d0e21e
LW
2654=item panic: last
2655
2656(P) We popped the context stack to a block context, and then discovered
2657it wasn't a block context.
2658
2659=item panic: leave_scope clearsv
2660
be771a83
GS
2661(P) A writable lexical variable became read-only somehow within the
2662scope.
a0d0e21e
LW
2663
2664=item panic: leave_scope inconsistency
2665
2666(P) The savestack probably got out of sync. At least, there was an
2667invalid enum on the top of it.
2668
810b8aa5
GS
2669=item panic: magic_killbackrefs
2670
2671(P) Failed an internal consistency check while trying to reset all weak
2672references to an object.
2673
6df41af2
GS
2674=item panic: malloc
2675
2676(P) Something requested a negative number of bytes of malloc.
2677
a0d0e21e
LW
2678=item panic: mapstart
2679
2680(P) The compiler is screwed up with respect to the map() function.
2681
2682=item panic: null array
2683
2684(P) One of the internal array routines was passed a null AV pointer.
2685
2686=item panic: pad_alloc
2687
2688(P) The compiler got confused about which scratch pad it was allocating
2689and freeing temporaries and lexicals from.
2690
2691=item panic: pad_free curpad
2692
2693(P) The compiler got confused about which scratch pad it was allocating
2694and freeing temporaries and lexicals from.
2695
2696=item panic: pad_free po
2697
2698(P) An invalid scratch pad offset was detected internally.
2699
2700=item panic: pad_reset curpad
2701
2702(P) The compiler got confused about which scratch pad it was allocating
2703and freeing temporaries and lexicals from.
2704
2705=item panic: pad_sv po
2706
2707(P) An invalid scratch pad offset was detected internally.
2708
2709=item panic: pad_swipe curpad
2710
2711(P) The compiler got confused about which scratch pad it was allocating
2712and freeing temporaries and lexicals from.
2713
2714=item panic: pad_swipe po
2715
2716(P) An invalid scratch pad offset was detected internally.
2717
2718=item panic: pp_iter
2719
2720(P) The foreach iterator got called in a non-loop context frame.
2721
2269b42e
JH
2722=item panic: pp_split
2723
2724(P) Something terrible went wrong in setting up for the split.
2725
a0d0e21e
LW
2726=item panic: realloc
2727
2728(P) Something requested a negative number of bytes of realloc.
2729
2730=item panic: restartop
2731
2732(P) Some internal routine requested a goto (or something like it), and
2733didn't supply the destination.
2734
2735=item panic: return
2736
2737(P) We popped the context stack to a subroutine or eval context, and
2738then discovered it wasn't a subroutine or eval context.
2739
2740=item panic: scan_num
2741
2742(P) scan_num() got called on something that wasn't a number.
2743
2744=item panic: sv_insert
2745
2746(P) The sv_insert() routine was told to remove more string than there
2747was string.
2748
2749=item panic: top_env
2750
6224f72b 2751(P) The compiler attempted to do a goto, or something weird like that.
a0d0e21e
LW
2752
2753=item panic: yylex
2754
2755(P) The lexer got into a bad state while processing a case modifier.
2756
dea0fc0b
JH
2757=item panic: utf16_to_utf8: odd bytelen
2758
2759(P) Something tried to call utf16_to_utf8 with an odd (as opposed
64977eb6 2760to even) byte length.
dea0fc0b 2761
7b8d334a 2762=item Parentheses missing around "%s" list
a0d0e21e 2763
e476b1b5 2764(W parenthesis) You said something like
a0d0e21e
LW
2765
2766 my $foo, $bar = @_;
2767
2768when you meant
2769
2770 my ($foo, $bar) = @_;
2771
54884818 2772Remember that "my", "our", and "local" bind tighter than comma.
a0d0e21e 2773
75b44862 2774=item Perl %s required--this is only version %s, stopped
a0d0e21e 2775
be771a83
GS
2776(F) The module in question uses features of a version of Perl more
2777recent than the currently running version. How long has it been since
2778you upgraded, anyway? See L<perlfunc/require>.
a0d0e21e 2779
6df41af2
GS
2780=item PERL_SH_DIR too long
2781
2782(F) An error peculiar to OS/2. PERL_SH_DIR is the directory to find the
fecfaeb8 2783C<sh>-shell in. See "PERL_SH_DIR" in L<perlos2>.
6df41af2
GS
2784
2785=item perl: warning: Setting locale failed.
2786
2787(S) The whole warning message will look something like:
2788
2789 perl: warning: Setting locale failed.
2790 perl: warning: Please check that your locale settings:
2791 LC_ALL = "En_US",
2792 LANG = (unset)
2793 are supported and installed on your system.
2794 perl: warning: Falling back to the standard locale ("C").
2795
2796Exactly what were the failed locale settings varies. In the above the
2797settings were that the LC_ALL was "En_US" and the LANG had no value.
0ea6b70f
JH
2798This error means that Perl detected that you and/or your operating
2799system supplier and/or system administrator have set up the so-called
2800locale system but Perl could not use those settings. This was not
2801dead serious, fortunately: there is a "default locale" called "C" that
2802Perl can and will use, the script will be run. Before you really fix
2803the problem, however, you will get the same error message each time
2804you run Perl. How to really fix the problem can be found in
2805L<perllocale> section B<LOCALE PROBLEMS>.
6df41af2 2806
bccbfa77
NC
2807=item perlio: argument list not closed for layer "%s"
2808
64977eb6 2809(S) When pushing a layer with arguments onto the Perl I/O system you forgot
bccbfa77 2810the ) that closes the argument list. (Layers take care of transforming
64977eb6
NC
2811data between external and internal representations.) Perl stopped parsing
2812the layer list at this point and did not attempt to push this layer.
2813If your program didn't explicitly request the failing operation, it may be
2814the result of the value of the environment variable PERLIO.
2815
2816=item perlio: invalid separator character %s in attribute list
2817
2818(S) When pushing layers onto the Perl I/O system, something other than a
d1be9408 2819colon or whitespace was seen between the elements of a layer list.
64977eb6
NC
2820If the previous attribute had a parenthesised parameter list, perhaps that
2821list was terminated too soon.
bccbfa77 2822
ef0f9817
DD
2823=item perlio: unknown layer "%s"
2824
2825(S) An attempt was made to push an unknown layer onto the Perl I/O
2826system. (Layers take care of transforming data between external and
2827internal representations.) Note that some layers, such as C<mmap>,
2828are not supported in all environments. If your program didn't
2829explicitly request the failing operation, it may be the result of the
2830value of the environment variable PERLIO.
2831
a0d0e21e
LW
2832=item Permission denied
2833
2834(F) The setuid emulator in suidperl decided you were up to no good.
2835
bd3fa61c 2836=item pid %x not a child
748a9306 2837
be771a83
GS
2838(W exec) A warning peculiar to VMS. Waitpid() was asked to wait for a
2839process which isn't a subprocess of the current process. While this is
2840fine from VMS' perspective, it's probably not what you intended.
748a9306 2841
3bf38418
WL
2842=item P must have an explicit size
2843
2844(F) The unpack format P must have an explicit size, not "*".
2845
5cd5c422
RB
2846=item POSIX syntax [%s] belongs inside character classes in regex;
2847
2848marked by <-- HERE in m/%s/
b45f050a 2849
9a0b3859 2850(W regexp) The character class constructs [: :], [= =], and [. .] go
7253e4e3
RK
2851I<inside> character classes, the [] are part of the construct, for example:
2852/[012[:alpha:]345]/. Note that [= =] and [. .] are not currently
2853implemented; they are simply placeholders for future extensions and will
2854cause fatal errors. The <-- HERE shows in the regular expression about
2855where the problem was discovered. See L<perlre>.
b45f050a 2856
5cd5c422
RB
2857=item POSIX syntax [. .] is reserved for future extensions in regex;
2858
2859marked by <-- HERE in m/%s/
b45f050a
JF
2860
2861(F regexp) Within regular expression character classes ([]) the syntax
7253e4e3
RK
2862beginning with "[." and ending with ".]" is reserved for future extensions.
2863If you need to represent those character sequences inside a regular
2864expression character class, just quote the square brackets with the
2865backslash: "\[." and ".\]". The <-- HERE shows in the regular expression
2866about where the problem was discovered. See L<perlre>.
b45f050a 2867
5cd5c422
RB
2868=item POSIX syntax [= =] is reserved for future extensions in regex;
2869
2870marked by <-- HERE in m/%s/
b45f050a 2871
7253e4e3
RK
2872(F) Within regular expression character classes ([]) the syntax beginning
2873with "[=" and ending with "=]" is reserved for future extensions. If you
2874need to represent those character sequences inside a regular expression
2875character class, just quote the square brackets with the backslash: "\[="
2876and "=\]". The <-- HERE shows in the regular expression about where the
2877problem was discovered. See L<perlre>.
b45f050a 2878
5cd5c422
RB
2879=item POSIX class [:%s:] unknown in regex;
2880
2881marked by <-- HERE in m/%s/
b45f050a 2882
7253e4e3
RK
2883(F) The class in the character class [: :] syntax is unknown. The <-- HERE
2884shows in the regular expression about where the problem was discovered.
80feea45
JH
2885Note that the POSIX character classes do B<not> have the C<is> prefix
2886the corresponding C interfaces have: in other words, it's C<[[:print:]]>,
2887not C<isprint>. See L<perlre>.
b45f050a 2888
a0d0e21e
LW
2889=item POSIX getpgrp can't take an argument
2890
81777298 2891(F) Your system has POSIX getpgrp(), which takes no argument, unlike
a0d0e21e
LW
2892the BSD version, which takes a pid.
2893
bbce6d69
PP
2894=item Possible attempt to put comments in qw() list
2895
e476b1b5 2896(W qw) qw() lists contain items separated by whitespace; as with literal
75b44862 2897strings, comment characters are not ignored, but are instead treated as
be771a83
GS
2898literal data. (You may have used different delimiters than the
2899parentheses shown here; braces are also frequently used.)
bbce6d69 2900
774d564b
PP
2901You probably wrote something like this:
2902
54310121 2903 @list = qw(
774d564b 2904 a # a comment
bbce6d69 2905 b # another comment
774d564b 2906 );
bbce6d69
PP
2907
2908when you should have written this:
2909
774d564b 2910 @list = qw(
54310121
PP
2911 a
2912 b
774d564b
PP
2913 );
2914
2915If you really want comments, build your list the
2916old-fashioned way, with quotes and commas:
2917
2918 @list = (
2919 'a', # a comment
2920 'b', # another comment
2921 );
bbce6d69
PP
2922
2923=item Possible attempt to separate words with commas
2924
be771a83
GS
2925(W qw) qw() lists contain items separated by whitespace; therefore
2926commas aren't needed to separate the items. (You may have used
2927different delimiters than the parentheses shown here; braces are also
2928frequently used.)
bbce6d69 2929
54310121 2930You probably wrote something like this:
bbce6d69 2931
774d564b
PP
2932 qw! a, b, c !;
2933
2934which puts literal commas into some of the list items. Write it without
2935commas if you don't want them to appear in your data:
bbce6d69 2936
774d564b 2937 qw! a b c !;
bbce6d69 2938
a0d0e21e
LW
2939=item Possible memory corruption: %s overflowed 3rd argument
2940
2941(F) An ioctl() or fcntl() returned more than Perl was bargaining for.
2942Perl guesses a reasonable buffer size, but puts a sentinel byte at the
2943end of the buffer just in case. This sentinel byte got clobbered, and
2944Perl assumes that memory is now corrupted. See L<perlfunc/ioctl>.
2945
18623440
PS
2946=item Possible unintended interpolation of %s in string
2947
2948(W ambiguous) You said something like `@foo' in a double-quoted string
32b0a12e
AMS
2949but there was no array C<@foo> in scope at the time. If you wanted a
2950literal @foo, then write it as \@foo; otherwise find out what happened
2951to the array you apparently lost track of.
18623440 2952
6df41af2
GS
2953=item Possible Y2K bug: %s
2954
2955(W y2k) You are concatenating the number 19 with another number, which
2956could be a potential Year 2000 problem.
2957
8cd79558
GS
2958=item pragma "attrs" is deprecated, use "sub NAME : ATTRS" instead
2959
a1063b2d 2960(D deprecated) You have written something like this:
8cd79558
GS
2961
2962 sub doit
2963 {
2964 use attrs qw(locked);
2965 }
2966
2967You should use the new declaration syntax instead.
2968
2969 sub doit : locked
2970 {
2971 ...
2972
2973The C<use attrs> pragma is now obsolete, and is only provided for
2974backward-compatibility. See L<perlsub/"Subroutine Attributes">.
2975
a0d0e21e
LW
2976=item Precedence problem: open %s should be open(%s)
2977
e476b1b5 2978(S precedence) The old irregular construct
cb1a09d0 2979
a0d0e21e
LW
2980 open FOO || die;
2981
2982is now misinterpreted as
2983
2984 open(FOO || die);
2985
be771a83
GS
2986because of the strict regularization of Perl 5's grammar into unary and
2987list operators. (The old open was a little of both.) You must put
2988parentheses around the filehandle, or use the new "or" operator instead
2989of "||".
a0d0e21e 2990
3cdd684c
TP
2991=item Premature end of script headers
2992
2993See Server error.
2994
6df41af2
GS
2995=item printf() on closed filehandle %s
2996
be771a83 2997(W closed) The filehandle you're writing to got itself closed sometime
c289d2f7 2998before now. Check your control flow.
6df41af2 2999
9a7dcd9c 3000=item print() on closed filehandle %s
a0d0e21e 3001
be771a83 3002(W closed) The filehandle you're printing on got itself closed sometime
c289d2f7 3003before now. Check your control flow.
a0d0e21e 3004
6df41af2 3005=item Process terminated by SIG%s
a0d0e21e 3006
6df41af2
GS
3007(W) This is a standard message issued by OS/2 applications, while *nix
3008applications die in silence. It is considered a feature of the OS/2
3009port. One can easily disable this by appropriate sighandlers, see
3010L<perlipc/"Signals">. See also "Process terminated by SIGTERM/SIGINT"
fecfaeb8 3011in L<perlos2>.
a0d0e21e 3012
3fe9a6f1 3013=item Prototype mismatch: %s vs %s
4633a7c4 3014
9a0b3859 3015(S prototype) The subroutine being declared or defined had previously been
be771a83 3016declared or defined with a different function prototype.
4633a7c4 3017
ed9aa3b7
SG
3018=item Prototype not terminated
3019
3020(F) You've omitted the closing parenthesis in a function prototype
3021definition.
3022
5cd5c422
RB
3023=item Quantifier in {,} bigger than %d in regex;
3024
3025marked by <-- HERE in m/%s/
9baa0206 3026
b45f050a 3027(F) There is currently a limit to the size of the min and max values of the
7253e4e3 3028{min,max} construct. The <-- HERE shows in the regular expression about where
b45f050a 3029the problem was discovered. See L<perlre>.
9baa0206 3030
5cd5c422
RB
3031=item Quantifier unexpected on zero-length expression;
3032
3033marked by <-- HERE in m/%s/
9baa0206 3034
b45f050a
JF
3035(W regexp) You applied a regular expression quantifier in a place where
3036it makes no sense, such as on a zero-width assertion. Try putting the
3037quantifier inside the assertion instead. For example, the way to match
3038"abc" provided that it is followed by three repetitions of "xyz" is
3039C</abc(?=(?:xyz){3})/>, not C</abc(?=xyz){3}/>.
9baa0206 3040
7253e4e3
RK
3041The <-- HERE shows in the regular expression about where the problem was
3042discovered.
3043
89ea2908
GA
3044=item Range iterator outside integer range
3045
3046(F) One (or both) of the numeric arguments to the range operator ".."
3047are outside the range which can be represented by integers internally.
be771a83
GS
3048One possible workaround is to force Perl to use magical string increment
3049by prepending "0" to your numbers.
89ea2908 3050
9a7dcd9c 3051=item readline() on closed filehandle %s
a0d0e21e 3052
75b44862 3053(W closed) The filehandle you're reading from got itself closed sometime
c289d2f7 3054before now. Check your control flow.
a0d0e21e 3055
6df41af2
GS
3056=item Reallocation too large: %lx
3057
3058(F) You can't allocate more than 64K on an MS-DOS machine.
3059
4ad56ec9
IZ
3060=item realloc() of freed memory ignored
3061
be771a83
GS
3062(S malloc) An internal routine called realloc() on something that had
3063already been freed.
4ad56ec9 3064
a0d0e21e
LW
3065=item Recompile perl with B<-D>DEBUGGING to use B<-D> switch
3066
be771a83
GS
3067(F debugging) You can't use the B<-D> option unless the code to produce
3068the desired output is compiled into Perl, which entails some overhead,
a0d0e21e
LW
3069which is why it's currently left out of your copy.
3070
3e0ccd42 3071=item Recursive inheritance detected in package '%s'
a0d0e21e
LW
3072
3073(F) More than 100 levels of inheritance were used. Probably indicates
3074an unintended loop in your inheritance hierarchy.
3075
7a4340ed 3076=item Recursive inheritance detected while looking for method %s
3e0ccd42 3077
be771a83
GS
3078(F) More than 100 levels of inheritance were encountered while invoking
3079a method. Probably indicates an unintended loop in your inheritance
3080hierarchy.
3e0ccd42 3081
1930e939
TP
3082=item Reference found where even-sized list expected
3083
be771a83
GS
3084(W misc) You gave a single reference where Perl was expecting a list
3085with an even number of elements (for assignment to a hash). This usually
3086means that you used the anon hash constructor when you meant to use
3087parens. In any case, a hash requires key/value B<pairs>.
7b8d334a
GS
3088
3089 %hash = { one => 1, two => 2, }; # WRONG
3090 %hash = [ qw/ an anon array / ]; # WRONG
3091 %hash = ( one => 1, two => 2, ); # right
3092 %hash = qw( one 1 two 2 ); # also fine
3093
810b8aa5
GS
3094=item Reference is already weak
3095
e476b1b5 3096(W misc) You have attempted to weaken a reference that is already weak.
810b8aa5
GS
3097Doing so has no effect.
3098
a0d0e21e
LW
3099=item Reference miscount in sv_replace()
3100
be771a83
GS
3101(W internal) The internal sv_replace() function was handed a new SV with
3102a reference count of other than 1.
a0d0e21e 3103
5cd5c422
RB
3104=item Reference to nonexistent group in regex;
3105
3106marked by <-- HERE in m/%s/
b45f050a
JF
3107
3108(F) You used something like C<\7> in your regular expression, but there are
3109not at least seven sets of capturing parentheses in the expression. If you
3110wanted to have the character with value 7 inserted into the regular expression,
3111prepend a zero to make the number at least two digits: C<\07>
9baa0206 3112
7253e4e3 3113The <-- HERE shows in the regular expression about where the problem was
b45f050a 3114discovered.
9baa0206 3115
a0d0e21e
LW
3116=item regexp memory corruption
3117
3118(P) The regular expression engine got confused by what the regular
3119expression compiler gave it.
3120
b45f050a 3121=item Regexp out of space
a0d0e21e 3122
be771a83
GS
3123(P) A "can't happen" error, because safemalloc() should have caught it
3124earlier.
a0d0e21e 3125
7a95317d
GS
3126=item Repeat count in pack overflows
3127
be771a83
GS
3128(F) You can't specify a repeat count so large that it overflows your
3129signed integers. See L<perlfunc/pack>.
7a95317d
GS
3130
3131=item Repeat count in unpack overflows
3132
be771a83
GS
3133(F) You can't specify a repeat count so large that it overflows your
3134signed integers. See L<perlfunc/unpack>.
7a95317d 3135
a0d0e21e
LW
3136=item Reversed %s= operator
3137
be771a83
GS
3138(W syntax) You wrote your assignment operator backwards. The = must
3139always comes last, to avoid ambiguity with subsequent unary operators.
a0d0e21e
LW
3140
3141=item Runaway format
3142
3143(F) Your format contained the ~~ repeat-until-blank sequence, but it
3144produced 200 lines at once, and the 200th line looked exactly like the
3145199th line. Apparently you didn't arrange for the arguments to exhaust
3146themselves, either by using ^ instead of @ (for scalar variables), or by
3147shifting or popping (for array variables). See L<perlform>.
3148
3149=item Scalar value @%s[%s] better written as $%s[%s]
3150
be771a83
GS
3151(W syntax) You've used an array slice (indicated by @) to select a
3152single element of an array. Generally it's better to ask for a scalar
3153value (indicated by $). The difference is that C<$foo[&bar]> always
3154behaves like a scalar, both when assigning to it and when evaluating its
3155argument, while C<@foo[&bar]> behaves like a list when you assign to it,
3156and provides a list context to its subscript, which can do weird things
3157if you're expecting only one subscript.
a0d0e21e 3158
748a9306 3159On the other hand, if you were actually hoping to treat the array
5f05dabc 3160element as a list, you need to look into how references work, because
748a9306
LW
3161Perl will not magically convert between scalars and lists for you. See
3162L<perlref>.
3163
a6006777
PP
3164=item Scalar value @%s{%s} better written as $%s{%s}
3165
75b44862 3166(W syntax) You've used a hash slice (indicated by @) to select a single
be771a83
GS
3167element of a hash. Generally it's better to ask for a scalar value
3168(indicated by $). The difference is that C<$foo{&bar}> always behaves
3169like a scalar, both when assigning to it and when evaluating its
3170argument, while C<@foo{&bar}> behaves like a list when you assign to it,
3171and provides a list context to its subscript, which can do weird things
3172if you're expecting only one subscript.
3173
3174On the other hand, if you were actually hoping to treat the hash element
3175as a list, you need to look into how references work, because Perl will
3176not magically convert between scalars and lists for you. See
a6006777
PP
3177L<perlref>.
3178
3e2f796a
NIS
3179=item Scalars leaked: %d
3180
3181(P) Something went wrong in Perl's internal bookkeeping of scalars:
3182not all scalar variables were deallocated by the time Perl exited.
3183What this usually indicates is a memory leak, which is of course bad,
3184especially if the Perl program is intended to be long-running.
3185
a0d0e21e
LW
3186=item Script is not setuid/setgid in suidperl
3187
54310121
PP
3188(F) Oddly, the suidperl program was invoked on a script without a setuid
3189or setgid bit set. This doesn't make much sense.
a0d0e21e
LW
3190
3191=item Search pattern not terminated
3192
3193(F) The lexer couldn't find the final delimiter of a // or m{}
3194construct. Remember that bracketing delimiters count nesting level.
fb73857a 3195Missing the leading C<$> from a variable C<$m> may cause this error.
a0d0e21e 3196
9ddeeac9 3197=item %sseek() on unopened filehandle
a0d0e21e 3198
be771a83
GS
3199(W unopened) You tried to use the seek() or sysseek() function on a
3200filehandle that was either never opened or has since been closed.
a0d0e21e
LW
3201
3202=item select not implemented
3203
3204(F) This machine doesn't implement the select() system call.
3205
ae21d580 3206=item Self-ties of arrays and hashes are not supported
68a4a7e4 3207
ae21d580
JH
3208(F) Self-ties are of arrays and hashes are not supported in
3209the current implementation.
68a4a7e4 3210
6df41af2 3211=item Semicolon seems to be missing
a0d0e21e 3212
75b44862
GS
3213(W semicolon) A nearby syntax error was probably caused by a missing
3214semicolon, or possibly some other missing operator, such as a comma.
a0d0e21e
LW
3215
3216=item semi-panic: attempt to dup freed string
3217
be771a83
GS
3218(S internal) The internal newSVsv() routine was called to duplicate a
3219scalar that had previously been marked as free.
a0d0e21e 3220
6df41af2 3221=item sem%s not implemented
a0d0e21e 3222
6df41af2 3223(F) You don't have System V semaphore IPC on your system.
a0d0e21e 3224
69282e91 3225=item send() on closed socket %s
a0d0e21e 3226
be771a83 3227(W closed) The socket you're sending to got itself closed sometime
c289d2f7 3228before now. Check your control flow.
a0d0e21e 3229
7253e4e3 3230=item Sequence (? incomplete in regex; marked by <-- HERE in m/%s/
7b8d334a 3231
7253e4e3 3232(F) A regular expression ended with an incomplete extension (?. The <-- HERE
b45f050a 3233shows in the regular expression about where the problem was discovered. See
be771a83 3234L<perlre>.
1b1626e4 3235
5cd5c422
RB
3236=item Sequence (?{...}) not terminated or not {}-balanced in regex;
3237
3238marked by <-- HERE in m/%s/
b45f050a
JF
3239
3240(F) If the contents of a (?{...}) clause contains braces, they must balance
7253e4e3
RK
3241for Perl to properly detect the end of the clause. The <-- HERE shows in
3242the regular expression about where the problem was discovered. See
3243L<perlre>.
a0d0e21e 3244
5cd5c422
RB
3245=item Sequence (?%s...) not implemented in regex;
3246
3247marked by <-- HERE in m/%s/
a0d0e21e 3248
b45f050a 3249(F) A proposed regular expression extension has the character reserved but
7253e4e3 3250has not yet been written. The <-- HERE shows in the regular expression about
b45f050a
JF
3251where the problem was discovered. See L<perlre>.
3252
5cd5c422
RB
3253=item Sequence (?%s...) not recognized in regex;
3254
3255marked by <-- HERE in m/%s/
a0d0e21e 3256
7253e4e3
RK
3257(F) You used a regular expression extension that doesn't make sense. The
3258<-- HERE shows in the regular expression about where the problem was
3259discovered. See L<perlre>.
a0d0e21e 3260
5cd5c422
RB
3261=item Sequence (?#... not terminated in regex;
3262
3263marked by <-- HERE in m/%s/
6df41af2
GS
3264
3265(F) A regular expression comment must be terminated by a closing
7253e4e3
RK
3266parenthesis. Embedded parentheses aren't allowed. The <-- HERE shows in
3267the regular expression about where the problem was discovered. See
3268L<perlre>.
6df41af2
GS
3269
3270=item 500 Server error
3271
3272See Server error.
3273
a5f75d66
AD
3274=item Server error
3275
3cdd684c 3276This is the error message generally seen in a browser window when trying
be771a83
GS
3277to run a CGI program (including SSI) over the web. The actual error text
3278varies widely from server to server. The most frequently-seen variants
3279are "500 Server error", "Method (something) not permitted", "Document
3280contains no data", "Premature end of script headers", and "Did not
3281produce a valid header".
9607fc9c
PP
3282
3283B<This is a CGI error, not a Perl error>.
3284
be771a83
GS
3285You need to make sure your script is executable, is accessible by the
3286user CGI is running the script under (which is probably not the user
3287account you tested it under), does not rely on any environment variables
3288(like PATH) from the user it isn't running under, and isn't in a
3289location where the CGI server can't find it, basically, more or less.
3290Please see the following for more information:
9607fc9c 3291
06a5f41f
JH
3292 http://www.perl.org/CGI_MetaFAQ.html
3293 http://www.htmlhelp.org/faq/cgifaq.html
3294 http://www.w3.org/Security/Faq/
a5f75d66 3295
be94a901
GS
3296You should also look at L<perlfaq9>.
3297
a0d0e21e
LW
3298=item setegid() not implemented
3299
be771a83
GS
3300(F) You tried to assign to C<$)>, and your operating system doesn't
3301support the setegid() system call (or equivalent), or at least Configure
3302didn't think so.
a0d0e21e
LW
3303
3304=item seteuid() not implemented
3305
be771a83
GS
3306(F) You tried to assign to C<< $> >>, and your operating system doesn't
3307support the seteuid() system call (or equivalent), or at least Configure
3308didn't think so.
a0d0e21e 3309
81777298
GS
3310=item setpgrp can't take arguments
3311
be771a83
GS
3312(F) Your system has the setpgrp() from BSD 4.2, which takes no
3313arguments, unlike POSIX setpgid(), which takes a process ID and process
3314group ID.
81777298 3315
a0d0e21e
LW
3316=item setrgid() not implemented
3317
be771a83
GS
3318(F) You tried to assign to C<$(>, and your operating system doesn't
3319support the setrgid() system call (or equivalent), or at least Configure
3320didn't think so.
a0d0e21e
LW
3321
3322=item setruid() not implemented
3323
be771a83
GS
3324(F) You tried to assign to C<$<>, and your operating system doesn't
3325support the setruid() system call (or equivalent), or at least Configure
3326didn't think so.
a0d0e21e 3327
6df41af2
GS
3328=item setsockopt() on closed socket %s
3329
be771a83
GS
3330(W closed) You tried to set a socket option on a closed socket. Did you
3331forget to check the return value of your socket() call? See
6df41af2
GS
3332L<perlfunc/setsockopt>.
3333
a0d0e21e
LW
3334=item Setuid/gid script is writable by world
3335
be771a83
GS
3336(F) The setuid emulator won't run a script that is writable by the
3337world, because the world might have written on it already.
a0d0e21e
LW
3338
3339=item shm%s not implemented
3340
3341(F) You don't have System V shared memory IPC on your system.
3342
6df41af2
GS
3343=item <> should be quotes
3344
3345(F) You wrote C<< require <file> >> when you should have written
3346C<require 'file'>.
3347
3348=item /%s/ should probably be written as "%s"
3349
3350(W syntax) You have used a pattern where Perl expected to find a string,
be771a83
GS
3351as in the first argument to C<join>. Perl will treat the true or false
3352result of matching the pattern against $_ as the string, which is
3353probably not what you had in mind.
6df41af2 3354
69282e91 3355=item shutdown() on closed socket %s
a0d0e21e 3356
75b44862
GS
3357(W closed) You tried to do a shutdown on a closed socket. Seems a bit
3358superfluous.
a0d0e21e 3359
f86702cc 3360=item SIG%s handler "%s" not defined
a0d0e21e 3361
be771a83
GS
3362(W signal) The signal handler named in %SIG doesn't, in fact, exist.
3363Perhaps you put it into the wrong package?
a0d0e21e
LW
3364
3365=item sort is now a reserved word
3366
3367(F) An ancient error message that almost nobody ever runs into anymore.