Hacker News new | ask | show | jobs
by bsmith 5000 days ago
I disagree.

> First of all PHP isn't about elegance...PHP is about getting stuff done.

What language isn't about getting stuff done?

> He doesn't offer one good valid technical reason why not to use comments...

Not true. The OP explicitly points out that it breaks many PHP debugging capabilities.

> The fact that you can even parse out comments with the reflection API lends, to me, that meta-programming is a-ok.

So what? PHP also has a goto function. Should we use it just because we can?

> I'll take the first one because I have other shit I need to do.

Just because it's less verbose doesn't mean it's better. Otherwise, everyone would use Coffeescript instead of JS.

2 comments

Many of the OPs complains have the tone of "not my PHP!!!".

If old PHP devs learn to look for annotations, points 2 and 4 no longer apply, and many points in 1 no longer apply either.

It sounds more like a PHP dev grumbling about change... (what else is new)

I am not opposed to change--in fact, I welcome it, especially with regard to PHP. Rather, I'm criticizing the use of annotations based on the argument that it is bad application design.
Making comments become as important as live code is never a good idea. This practice also encourages arbitrary syntax and would eventually lead to a mess of different standards with no cohesion.

Having a proper `pragma` declaration would be ideal.

> PHP also has a goto function. Should we use it just because we can?

Definitely yes. Use it whenever fit.