Typowe komunikaty ostrzeżeń i błędów w Perlu
O ile komunikaty ostrzeżeń i błędów zgłaszane przez Perla są całkiem dokładne, nie zawsze są one bardzo przyjazne dla początkujących. W tych artykułach znajdziesz kilka najbardziej powszechnych ostrzeżeń i błędów, które napotkasz, wytłumaczonych, mam nadzieję, w sposób bardziej przyjazny początkującym.
Niektóre z artykułów nawet zawierają wskazówki jak naprawić dany błąd.
- Global symbol requires explicit package name wytłumaczone także w Deklaracja zmiennych w Perlu
- Use of uninitialized value
- Bareword not allowed while "strict subs" in use
- Name "main::x" used only once: possible typo at ...
- Unknown warnings category
- Can't use string ("Foo") as a HASH ref while "strict refs" in use at ... opisane w Symbolic references in Perl
- Can't locate ... in @INC
- Scalar found where operator expected
- "my" variable masks earlier declaration in same scope
- Can't call method ... on unblessed reference
- Argument ... isn't numeric in numeric ...
- Can't locate object method "..." via package "1" (perhaps you forgot to load "1"?)
- Odd number of elements in hash assignment
- Possible attempt to separate words with commas
- Undefined subroutine ... called
perldiag także posiada dłuższe tłumaczenia dla każdego z tych błędów i ostrzeżeń, które możesz przejrzeć, albo możesz dotrzeć do szczegółowego tłumaczenia używając diagnostics lub splain.

Published on 2015-11-16
If you have any comments or questions, feel free to post them on the source of this page in GitHub. Source on GitHub.
Comment on this post