You are viewing a plain text version of this content. The canonical link for it is here.
Posted to docs-dev@perl.apache.org by Jan Kratochvil <la...@jankratochvil.net> on 2005/09/18 01:27:20 UTC

Small but important typo

Hi,

attached patch is for:
	http://search.cpan.org/~gozer/mod_perl-2.0.1/docs/api/APR/Table.pod

and its:
	$table->add("a" => 1);
	$table->add("b" => 2);
	$table->add("c" => 3);

	($k, $v) = each %$table; # (a, 1)
	print $table->{a};       # prints 1

	($k, $v) = each %$table; # (b, 2)
	print $table->{a};       # prints 1

	($k, $v) = each %$table; # (a, 3)
	print $table->{a};       # prints 3 !!!

	($k, $v) = each %$table; # (undef, undef)
	print $table->{a};       # prints 1

while in fact it DID NOT print 3, it was still printing 1...


Regards,
Lace

Re: Small but important typo

Posted by Stas Bekman <st...@stason.org>.
Jan Kratochvil wrote:
> Hi,
> 
> attached patch is for:
> 	http://search.cpan.org/~gozer/mod_perl-2.0.1/docs/api/APR/Table.pod
> 
> and its:
[...]
> Index: api/APR/Table.pod
> ===================================================================
> --- api/APR/Table.pod	(revision 289859)
> +++ api/APR/Table.pod	(working copy)
> @@ -976,7 +976,7 @@
>  
>    $table->add("a" => 1);
>    $table->add("b" => 2);
> -  $table->add("c" => 3);
> +  $table->add("a" => 3);

Thanks Jan, commited.

-- 
__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://mailchannels.com

---------------------------------------------------------------------
To unsubscribe, e-mail: docs-dev-unsubscribe@perl.apache.org
For additional commands, e-mail: docs-dev-help@perl.apache.org