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