On 12/10/06, Matisse Enzer [EMAIL PROTECTED] wrote:
Now in a CPAN near you: Perl::Metrics::Simple 0.30
Ah, the old Simple versus Basic argument:
http://search.cpan.org/dist/Perl-Metric-Basic/
Leon, who has already renamed it once to please Adam.
Matisse Enzer wrote:
On Dec 15, 2006, at 10:13 PM, Chris Dolan wrote:
OK, I see. Perhaps I was distracted from your main point by mention
of cyclomatic complexity, which has a rather specific definition.
Mea culpa.
In the next release I will change the documentation for
On Dec 16, 2006, at 12:07 PM, Matisse Enzer wrote:
On Dec 15, 2006, at 10:13 PM, Chris Dolan wrote:
OK, I see. Perhaps I was distracted from your main point by
mention of cyclomatic complexity, which has a rather specific
definition.
Mea culpa.
In the next release I will change the
On Dec 14, 2006, at 11:20 PM, Matisse Enzer wrote:
On Dec 14, 2006, at 3:05 PM, Michael G Schwern wrote:
Matisse Enzer wrote:
sub complexity_of_six {
my $bar = shift;
my $total = 0;
my $type = ref $bar;
if ( ! $type ) {
$total = $bar;
}
Chris Dolan wrote:
That can't be right. Negation does not contribute to complexity.
Instead, I believe it is the for loop and the exit points that are
increasing your count. Consider rewriting the for as ifs and gotos:
sub complexity_of_six {
my $bar = shift;
my $total
On Dec 15, 2006, at 7:52 AM, Chris Dolan wrote:
That can't be right. Negation does not contribute to complexity.
I think it is fair to say, that to a human, negation *can* increase
complexity:
if ( $foo ) {
# do something
}
is a little bit easier to understand than:
if
On Dec 15, 2006, at 10:22 PM, Matisse Enzer wrote:
On Dec 15, 2006, at 7:52 AM, Chris Dolan wrote:
That can't be right. Negation does not contribute to complexity.
I think it is fair to say, that to a human, negation *can* increase
complexity:
if ( $foo ) {
# do something
On Dec 10, 2006, at 1:16 AM, Ovid wrote:
--- Matisse Enzer [EMAIL PROTECTED] wrote:
McCabe Complexity
-
Code not in any subroutine::
min: 1
max 10
mean: 1.00
std. deviation: 2.54
median: 1.00