Hi!

> I'd like to propose opening an rfc to make the following syntax legal:
> 
> foreach($array as (int) $i) {}
> 
> Which would be functionally equivalent to
> 
> foreach($array as $i) {
> $i=(int) $i;
> }

This doesn't seem to add anything to existing functionality - what's
wrong with just making explicit cast, so that it's clear what is being
done? Traditionally, PHP opts to the side of clarity rather than brevity.

-- 
Stas Malyshev
smalys...@gmail.com

-- 
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to