Tag Archive for 'php5'

Type cast in PHP: doing the trick beyond the language

Following my last two posts (in portuguese, here and here) about class juggling in PHP I started getting some google hits on “cast class in PHP”.

A couple of days after I just have to duh! myself in the head a couple of times for whining about it and not thinking around the problem: I found a really simple, quick and dirty solution.

Click para continuar a ler “Type cast in PHP: doing the trick beyond the language”

Uma vantagem do type-cast em PHP seria fazer mais EAFP e menos LBYL

Note:for English readers hitting this post: written in Portuguese, about a non-existing feature (variable class type cast) of php5, bith 5 and 6, and one good-argument on how it would improve the language.

UPDATE: check this post for a “solution” to class cast in PHP.

No meu post anterior referi-me a uma característica do PHP que eu vejo como uma limitação, no sentido que limita - acima de tudo - a performance do meu trabalho no dia-a-dia.

Click para continuar a ler “Uma vantagem do type-cast em PHP seria fazer mais EAFP e menos LBYL”

Limitações do PHP: verdadeiro type cast

Note:for English readers hitting this post: written in Portuguese, about a non-existing feature (variable class type cast) of php5, bith 5 and 6, and one good-argument on how it would improve programming efficiency through ide improved functionality.

UPDATE: check this post for a “solution” to class cast in PHP.

Escrevo este post como verdadeiro fã do PHP. Mas não como aquele que se limita a louvar as suas potencialidades, antes como aquele que gostava que o PHP evoluísse e se tornasse ainda mais poderoso.

Click para continuar a ler “Limitações do PHP: verdadeiro type cast”







Close
E-mail It
1