Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
bgColor#ccccff
langperl
my $result = compute_number();
print "The result is $result\n";

Related Guidelines

CERT C Secure Coding Standard: DCL31-C. Declare identifiers before using them

Risk Assessment

Using undeclared variables usually can lead to incorrect results and surprising program behavior.

...

Tool

Diagnostic

use warnings;

Name .* used only once. possible typo

use strict;Global symbol .* requires explicit package name

Perl::Critic

 

Policy::TestingAndDebugging::RequireUseWarnings

Policy::TestingAndDebugging::RequireUseStrict

Bibliography

...

Related Guidelines

Bibliography

 

...

Image ModifiedImage ModifiedImage Modified