Re: foreach() using current() strange beahvior

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 6/23/07, Robert Cummings <robert@xxxxxxxxxxxxx> wrote:
Regardless of additional documentation or not, I think it's rather poor
choice of programming style to mix the foreach construct with the older,
lower level, internal array manipulation and probing functions. I think
that is what should be documented since you just might get weird
results :)

i agree; at least i have never had a need to determine the current index of
the internal array pointer in nearly 3 years working w/ php.
although it is somewhat interesting to experiment w/ the language to see how
it behaves :)

-nathan


On 6/23/07, Robert Cummings <robert@xxxxxxxxxxxxx> wrote:

On Sat, 2007-06-23 at 15:15 -0400, Nathan Nobbe wrote:
>
> in summary, COW or not; i think the documentation could be revised a bit
to
> clarify these subtleties.

Regardless of additional documentation or not, I think it's rather poor
choice of programming style to mix the foreach construct with the older,
lower level, internal array manipulation and probing functions. I think
that is what should be documented since you just might get weird
results :)

Cheers,
Rob.
--
.------------------------------------------------------------.
| InterJinn Application Framework - http://www.interjinn.com |
:------------------------------------------------------------:
| An application and templating framework for PHP. Boasting  |
| a powerful, scalable system for accessing system services  |
| such as forms, properties, sessions, and caches. InterJinn |
| also provides an extremely flexible architecture for       |
| creating re-usable components quickly and easily.          |
`------------------------------------------------------------'



[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux