3 ms·
What's the problem with '$'?
by nerdbert 4y ago
What's the problem with '$'?
- xigoi 4y agoFor me, it makes code harder to read because my brain can't stop pronouncing it as “s”, so something like `f($x, $y, $z)` reads like “eff sex, swy, szee”. And for writing, requiring a shifted key before every identifier is a lot of pinky strain. Not to mention that it's completely useless noise.
- dncornholio 4y agoLife is too short to care about stuff like this. It's like saying you don't like the color blue.
- xigoi 4y agoCarpal tunnel syndrome is nothing to take lightly.
- withinboredom 4y agoBut it lets you do things that are absolutely wild without weird syntax or setting up reflection. $obj->$dynamic_var. Or $$dynamic_obj->$dynamic_fun(). Whether or not you should be doing that is another matter… but it’s useful in some cases and easier to grok than using reflection or using array syntax on an object (like JavaScript). After awhile, you don’t even notice the $ to be honest.
- antifa 4y agoIt must be embrassing when you read outloud "S-S-SWone thousand dollars".