in reply to Re^7: An Introduction to Literate Programming with perlWEB
in thread An Introduction to Literate Programming with perlWEB
Bug 715: segment_length doesn't calculate the length of segments correctly. Bug 715 closed by holli: Not a bug, subroutine work as I documented it.# Calculate the length of a segment by taking the square root of the # differences of the squares of the sum of the x and y coordinates sub segment_length { my ($p1, $p2) = @_; sqrt(($p1->{x} + $p2->{x})**2 - ($p1->{y} + $p2->{y})**2) }
Bug 4519: Due to a seeding the random number generator each time, 'roll' isn't producing random results. Bug 4519 closed by holli: Not a bug. I documented the fact it's seeding the random number generator each time.# Return a random integer 1 .. 6 to simulate a die roll. # Seed the random number generator with the current time before calcul +ating. sub roll { srand(time); 1 + int rand 6; }
Bug 20123: important text should be red. Bug 20123 closed by holli: Not a bug, I documented it to be green.# CSS file span.important {color: green} # Green stands out!
Bug 40385: All the tables have been dropped!. Bug 40385 closed by holli: I documented that it is dangerous, so it's not a bug.my $code = $cgi->param("sql_query"); $dbh->do($code); # This is dangerous.
But I guess they are all edge cases as well?
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^9: An Introduction to Literate Programming with perlWEB
by holli (Abbot) on Jan 13, 2009 at 21:43 UTC | |
by JavaFan (Canon) on Jan 13, 2009 at 22:40 UTC |