this post was submitted on 24 Aug 2025
456 points (98.9% liked)

Programmer Humor

25958 readers
903 users here now

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

founded 2 years ago
MODERATORS
 
you are viewing a single comment's thread
view the rest of the comments
[–] bleistift2@sopuli.xyz 17 points 1 day ago (2 children)

Fuck that. I once used a constraint solver in python where you could += a constraint to a problem. This is completely un-discoverable. In any sane language you can use IntelliSense to find that you can problem.add(constraint) and be done with it without ever touching a manual. Overloaded operators are cool, but a menace.

And while I’m ranting: Angular’s new addRouting(), withThingA(), withThingB() is complete horseshit, too. The old way of doing addRouter({ and letting the IDE tell you what you could to with the router was so much clearer!

[–] _stranger_@lemmy.world 3 points 1 day ago* (last edited 1 day ago)

I'll take overloaded operators over overloaded functions any day of the week, and I also hate overloaded operators.

Python's optional typing has come a very long way in the past few years, you might be able to mitigate this with some creative application of typing.

Edit: I read your post closer, I'm not sure typing would help with the overloaded operator issue and now I have something fun to try out later 😁

[–] marcos@lemmy.world 0 points 1 day ago

Any good inline help would run dir into your variable and discover it overloads that operator. It's a fault of your tools.