3 ms·
I disagree that PHP does not have a consistent design. Since PHP 7 they have been intentionally removing all old PHP warts and pushing the language to real cons
by no_wizard 8y ago
I disagree that PHP does not have a consistent design. Since PHP 7 they have been intentionally removing all old PHP warts and pushing the language to real consistency. They even have an RFC process now for proposing new features from the community so they can be more responsive.
It’s not statically typed like Go but it’s far from inconsistent IMO
- tene 8y agoI feel confused. Are you really saying that your justification for PHP having a consistent design is that, on its seventh major version, twenty years into its lifetime, an effort has been started to attempt to establish consistency by removing some old features, and adopting a community RFC process, or am I misunderstanding your claim here?
- deleted 8y ago[deleted]
- omnimus 8y agoI do PHP a lot and it is extremely inconsistent. Even PHP7. Like half of standard library uses _ and other half does without them (var_dump(), phpinfo(), gettype(), get_class()). Half uses to other half 2 (deg2rad(), strtotime()). So many bugs because of comparsion and operators doing wierd stuff. PHP is mad. I think they have to keep it for legacy reasons. Don't get me wrong i think the way php handles requests is useful for the small websites i create and i would probably not use any other language for that. But PHP is THE dirtiest most inconsistent language that people actually use.
- no_wizard 8y agoPerhaps I have a little bit of a knee jerk reaction. I've gotten a new job where I have to do php development pretty heavy, and I haven't done it since I was 19 when I was interning at my first programming job and I absolutely hated it. Back then php 5.5 I think was the latest version and it just felt incredibly impossible to get anywhere with it. It wasn't long after that I moved to Python. I only recently got a different job all these years later where I am doing it again but PHP 7 is just so much better. 7.2 in particular even though its a point release has even done a lot to improve it. So I feel like there is this level of people who look at people who have to do PHP and actually enjoy it (and I have to say I am enjoying it, warts and all. Drupal is OK but where it really shines is https://laravel.com https://laravel.com ) like we aren't 'real' programmers unless we somehow know its a terrible language and are only doing it because we have to. I really like it. With that said, if I'm being completely honest here, there are parts of the PHP community that just down right drive me nuts. There are a lot of scammy companies out there trying to sell PHP solutions that are such garbage. Its like JavaScript. PHP does have a low barrier to entry (but a high bar to being good at wielding it, much like JS. You could probably make this argument for a lot of web tech in general) that all kinds of people use it and really feels like it sullies the language quite a bit and some of the community around it. Alas however, much like everyone hating jQuery without ever actually explaining themselves or what is the technical aspects of jQuery that make it so undesirable, PHP occupies the same space: everyone loves to hate it, it seems.
- slavak 8y agohttps://eev.ee/blog/2012/04/09/php-a-fractal-of-bad-design/ https://eev.ee/blog/2012/04/09/php-a-fractal-of-bad-design/ > Unlike (literally!) every other language with a similar operator, ?: is left associative. So this: $arg = 'T'; $vehicle = ( ( $arg == 'B' ) ? 'bus' : ( $arg == 'A' ) ? 'airplane' : ( $arg == 'T' ) ? 'train' : ( $arg == 'C' ) ? 'car' : ( $arg == 'H' ) ? 'horse' : 'feet' ); echo $vehicle; > prints horse. In what world is this sane language design?!