Hacker News new | past | comments | ask | show | jobs | submit login

What's so hard about OO? Instead of string_length($string), you write $string->length. The semantics are the same. If you pass something other than a string to string_length, the results are undefined. If you call length on an object that doesn't do the length method, then you get an error.

The attraction of PHP is that it never tells you that you're writing code that doesn't work. The result is a lot of code that doesn't work. This is bad, not good.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: