3,292 karma · joined Jul 1, 2013 (13y ago) · 1,194 submissions
comment 7y ago · link · parent
You need a protocol over TCP. Something standard and easy to use, hopefully one that people already know and has wide support from libraries. HTTP?
Native UIs are nice, but the cool kids like to stylize their UIs. Things like gradients, shadows, highlights, animations, etc. And wouldn't it be cooler if you go to all that trouble to stylize your UI to have it look the same on all platforms? What if you add another layer on top of the underlying UI framework? Something that lets you compose UI elements from basic shapes, maybe a way to separate the layout from the style? HTML + CSS.
Oh wait, we reinvented electron again.
comment 7y ago · link · parent
comment 7y ago · link · parent
https://github.com/nothings/stb/blob/master/stb_image.h#L120
comment 7y ago · link · parent
> If they took the time to have “relaxation” rooms, i doubt its as bad as the story makes it out to be.
The article said:
> Facebook contractors are required to use a browser extension to report every time they use the restroom, but during a recent illness, Lola quickly took all her allotted breaks. She had previously been written up for going to the bathroom too many times, she said, and so she felt afraid to get up from her desk. A manager saw that she was not feeling well, and brought a trash can to her desk so she could vomit in it. So she did.
comment 7y ago · link · parent
> Do we really want to be haunted by our past in such a way?
To which my reply was: let's be mature about it and not care about trivialities from someone's past.
Now you change the subject to: "What if its you kid who's being bullied or who got bullied?". My kid being bullied "right now" is not the same as "my kid did some stupid shit 10 years ago and people are making fun of him now because of it". This is another problem with another solution, and it's not something I argued about.
comment 7y ago · link · parent
Mobs have short attention span and are mobilized by the newest controversy of the day. We're talking about recording history. You remove a bug from git, but you don't alter the entire history for it. You remove passwords from git, but you also change the current passwords.
There's no reason we can't 'fix' the present and record the past at the same time.
comment 7y ago · link · parent
> You are simultaneously reaffirming your neighbor's standards for themselves, and rejecting them for yourself.
Yes, because we are complex, subjective, multidimensional humans, and we can judge each other based on different referential systems. If I don't care about your subjective perspective, I don't have to prove myself in your eyes. And if I don't care what your referential system is then I'm only a hypocrite in your eyes.
- You have a clean yard, you must be a good person. I have a messy yard, but I like it / I don't care. I can still be a good person for other reasons, but I don't care to be that person in your eyes. I do care that you're pestering me with comments, so please stop.
comment 7y ago · link · parent
I'm all for learning and debating, but this comes off awfully patronizing.
> In a sound design, objects more usually get their attributes at construction time, and keep them until they are destroyed.
Immutable objects are nice and I always try to use them when I can, but arguing that everything should be immutable or you have a design problem... that's exaggerated.
> When something needs to change, from outside the object, it is usually better to make another object.
As with everything, there's a trade-off with any solution. Allocating and copying data isn't cheap. And the fact that you just pick one way of doing things and discard anything else as "bad design" doesn't inspire confidence.
> The key here is that the public member functions should be doing useful work for you.
No, the "key" is that you are abstracting access to data. Your setter may do validation or transformation on the data. You may only offer const access to data. You may even do a defensive copy of the data. You may set breakpoints or log access to the data.
> If the object doesn't abstract anything, it isn't earning it keep.
Not all objects need to represent functionality. Some represent data. And mutating data is fundamentally what every program does. Just because you have an aversion to mutating data outside your object and you are willing to pay the price for immutable structures, doesn't mean everyone else is following a "classic anti-pattern".
> Another indicator of bad design is public virtual functions.
I really don't see the wisdom behind this one.