Readit News logoReadit News
mariodiana commented on The Big OOPs: Anatomy of a Thirty-Five Year Mistake   computerenhance.com/p/the... · Posted by u/SerCe
ocrow · a month ago
To unpack that a little, he looks to the writings of the early developers of object oriented programming and identifies the ways this assumption became established. People like Bjarne Stroustrup (developer of C++) took on and promulgated the view that the inheritance hierarchy of classes in an object oriented system can be or should be a literal instantiation of the types of objects from the domain model (e.g. different types of shapes in a drawing program).

This is a mistake is because it puts the broad-scale modularization boundaries of a system in the wrong places and makes the system brittle and inflexible. A better approach is one where large scale system boundaries fall along computational capability lines, as exemplified by modern Entity Component Systems. Class hierarchies that rigidly encode domain categorizations don't make for flexible systems.

Some of the earliest writers on object encapsulation, e.g. Tony Hoare, Doug Ross, understood this, but later language creators and promoters missed some of the subtleties of their writings and left us with a poor version of object-oriented programming as the accepted default.

mariodiana · a month ago
Is Objective-C discussed at all?
mariodiana commented on ICEBlock, an app for anonymously reporting ICE sightings, goes viral   techcrunch.com/2025/07/01... · Posted by u/exiguus
neither_color · 2 months ago
I don't see what's so bad about wanting to avoid an area where there's police activity going on. It has nothing to do with whether or not you're doing anything wrong, it's as simple as not wanting to get hassled at a DUI checkpoint or get stuck in traffic because they need 8 squad cars taking up a lane to k-9 search someone. As a more tan law-abiding US citizen, the possibility of some agent asking me for papers and then asking probing questions to "prove myself" anywhere that's not an airport is enough for me to want a heads up not to be in area where that might happen.
mariodiana · 2 months ago
Unless I'm mistaken, I remember some years ago the Apple Store blocked a DUI Checkpoint app. Has that changed?
mariodiana commented on US Supreme Court limits federal judges' power to block Trump orders   theguardian.com/us-news/2... · Posted by u/leotravis10
msgodel · 2 months ago
That ship sailed almost 100 years ago. If you really don't like it you should be campaigning for secession.

Remember: federal power is delegated from the states, not the other way around.

mariodiana · 2 months ago
My understanding is that your characterization is true of the Articles of Confederation, but not true of the Constitution. The federal government's power is delegated from the people.

At the top of the Articles, it's pretty clear that the delegates of the states have come together to establish a league of states. At the top of the Constitution, it's explicitly stated that "We the People […] do ordain and establish."

mariodiana commented on ICE Deports 3 U.S. Citizen Children Held Incommunicado Prior to the Deportation   aclu.org/press-releases/i... · Posted by u/mandmandam
tomrod · 4 months ago
This is not accurate, though I have found that people who steep in rightwing propaganda tend to repeat these type of talking points.

The Rawlsian veil ethic applies here.

EDIT: RE - the knee-jerk downvotes. I appreciate that people pointing out authoritarianism can be painful if you are embracing it. Cognitive dissonance is never a fun thing to work through, and having done it a few times I sympathize with the struggles you face or may be facing.

mariodiana · 4 months ago
I'm not going to downvote you. But Rawls never applies. Rawls is a big scam. At root, it is relativism wrapped up in the august raiment of state-of-nature social contract theory, whatever his protests to the contrary; and the relativism in this case is what "feels right" to him and his fancy neighbors living in Cambridge.
mariodiana commented on ICE Deports 3 U.S. Citizen Children Held Incommunicado Prior to the Deportation   aclu.org/press-releases/i... · Posted by u/mandmandam
cryptoegorophy · 4 months ago
What’s the conversation? Separating kids from parents or deporting them with parents because we don’t want them to be separate? There is no question about breaking the law by parents. Question is do you let children be with their mothers(who apparently asked to do so) or no.

As someone who came legally to Canada and went through thorough screening of 4 years before coming I just don’t get how people are ok with “cheaters” gaming the system.

“Think of the children” works when you are in a super white rich neighborhood, if you never lived in slums you won’t understand the abuse of the system by “think of the children”, you just don’t see it from the other side.

mariodiana · 4 months ago
Exactly. Children belong with their parents. And if their parents don't belong here, then Q.E.D.
mariodiana commented on Ask HN: Are You Polite to AI?    · Posted by u/orixilus
mariodiana · 5 months ago
I anthropomorphize A.I. not for its sake but for mine. I figure that my brain has evolved to interact with other humans, so maybe my thinking is better stimulated when I pretend I'm talking to one.
mariodiana commented on Think tank seeks to give "Trump his rightful third term in office"   thirdtermproject.com/... · Posted by u/krunck
mariodiana · 6 months ago
The fact that this would require a constitutional amendment makes me think this is more about collecting names to later pester for money than anything else. I wouldn't even take it seriously.

"Make bank. Troll the libs." The people behind this see it as a win-win.

Deep breaths, people. Deep breaths.

mariodiana commented on Liskov Substitution: The real meaning of inheritance   cekrem.github.io/posts/li... · Posted by u/cekrem
bedobi · 7 months ago
Do yourself a favor and wear yourself off all this SOLID, Uncle Bob, Object Oriented, Clean Code crap.

Don't ever use inheritance. Instead of things inheriting from other things, flip the relationship and make things HAVE other things. This is called composition and it has all the positives of inheritance but none of the negatives.

Example: imagine you have a school system where there are student users and there are employee users, and some features like grading that should only be available for employees.

Instead of making Student and Employee inherit from User, just have a User class/record/object/whatever you want to call it that constitutes the account

    data class User (id: Int, name: String, email: String)
and for those Users who are students, create a Student that points to the user

    data class Student (userId: Id, blabla student specific attributes)
and vice versa for the Employees

    data class Employee (userId: Id, blabla employee specific attributes)
then, your types can simply and strongly prevent Students from being sent into functions that are supposed to operate on Employees etc etc (but for those cases where you really want functions that operate on Users, just send in each of their Users! nothing's preventing you from that flexibility if that's what you want)

and for those users who really are both (after all, students can graduate and become employees, and employees can enroll to study), THE SAME USER can be BOTH a Student and an Employee! (this is one of the biggest footguns with inheritance: in the inheritance world, a Student can never be an Employee, even though that's just an accident of using inheritance and in the real world there's actually nothing that calls for that kind of artificial, hard segregation)

Once you see it you can't unsee it. The emperor has no clothes. Type-wise functional programmers have had solutions for all these made up problems for decades. That's why these days even sane Object Oriented language designers like Josh Bloch, Brian Goetz, the Kotlin devs etc are taking their languages in that direction.

mariodiana · 7 months ago
It's sad that late-binding languages like Objective-C never got the love they should have, and instead people have favored strongly (or stronger) typed languages. In Objective-C, you could have your User class take a delegate. The delegate could either handle messages for students or employees. And you could code the base User object to ignore anything that couldn't be handled by its particular delegate.

This is a very flexible way of doing things. Sure, you'll have people complain that this is "slow." But it's only slow in computer standards. By human standards—meaning the person sitting at a desktop or phone UI—it's fast enough that they'll never notice.

mariodiana commented on It's 10am and Dad's Doing Jell-O Shots. Must Be Parents' Weekend   wsj.com/lifestyle/parenti... · Posted by u/zeroonetwothree
AstroJetson · 9 months ago
Completely off topic, I lived in Fredonia around that time. I worked at the school, so I pretty much hung out in the townie bars (Coughlan's and an family run bar/italian restaurant I'm blanking on) . What was the big party bar you are talking about?
mariodiana · 9 months ago
Sunny's. I know it was actually a dance bar. I hung out a lot at Rooney's and sometimes the OMI.

On the one side of Sunny's was a gym. On the other side was a Sears catalog showroom. Above the Sears were two apartments. My friends and I lived in one of them. I was a music major, as was another one of us. The other two were graphic design and communications, respectfully.

The Sears was at the end of the street, at the start of which was the police department. It was a one-way street, so the cops were always traveling past. My understanding is that the Sears eventually turned into a topless bar, after the Sears showrooms went out of business.

Where did you work at the school? I worked for a short time in the food service. I waited tables at the Topiary Tree. I also was part of the wait staff for events at the president's house.

mariodiana commented on It's 10am and Dad's Doing Jell-O Shots. Must Be Parents' Weekend   wsj.com/lifestyle/parenti... · Posted by u/zeroonetwothree
mariodiana · 9 months ago
Graduation weekend 1989 at SUNY Fredonia, my housemate's father was visiting. We were four guys sharing an apartment right next door to the biggest party bar in town. At some point during the night before ceremonies, in the midst of our revelries, my one housemate went out through one of our apartment's windows and onto the roof, followed immediately by my other housemate's father. The cops were, at that moment, in the street breaking up some kind of fight outside the bar. A cop turned and shined his flashlight on the two of them on the roof. The two of them, visiting dad and my other housemate, in response, gave the cops the finger. Good times!

u/mariodiana

KarmaCake day1970November 21, 2013View Original