Readit News logoReadit News
i_am_a_peasant commented on Pro-democracy HK tycoon Jimmy Lai convicted in national security trial   bbc.com/news/articles/cp8... · Posted by u/onemoresoop
epistasis · 19 hours ago
The Arab Spring is a bad example if you're trying to say that the US is installing governments... South America's history provides far better examples.

That said, the US doesn't need to be perfect to still be an example of providing freedom for its own citizens.

i_am_a_peasant · 33 minutes ago
for its own citizens that were fortunate enough to be born at the right place at the right time. how should the rest of the world feel about the US if they get all the freedoms, comforts and opportunities and the rest of the world doesn’t?

Is that a country to be admired by all others or resented.

i_am_a_peasant commented on Ask HN: What Are You Working On? (December 2025)    · Posted by u/david927
stanko · 2 days ago
I’m working on a video game, purely for fun.

Here is a work in progress build:

https://muffinman-io.itch.io/space-deck-x

It is a combination of a shoot-em-up and deck building. You fly and shoot until you get to the boss, when you get your deck out to fight them.

That genre combination is definitely too ambitious, but I think it is fun to play and I’m enjoying making it.

I have a bunch of ideas how to combine the two parts better. But over the years, I’ve learned to control scope creep and actually ship pet projects.

Right now I’m in a middle of changing how enemy waves are spawned. After that I want to make a short tutorial and add two more bosses as well as more enemies.

If you end up playing it, please share your feedback I’ll be glad to hear it.

The game is made using Kaplay, a game dec library which brings me joy to use. I can best describe it as my friend described Pico-8: “easy things are easy”. But compared to Pico-8, Kaplay doesn’t have virtual console limitations and comes with a big library of components. Try it out, the community is small, but the library itself is really fun and easy to use.

EDIT: For context, this is about two weeks of work, in the evenings when my kid is asleep.

i_am_a_peasant · 2 days ago
i wish i was that good at pixel art, it would be my sole hoby if i were
i_am_a_peasant commented on Surface Tension of Software   iamstelios.com/blog/surfa... · Posted by u/i8s
jstimpfle · 2 days ago
> Could you please expand upon your idea that [..] a hierarchical structure of "blackboxes" [...] is bad?

You'll notice yourself when you try to actually apply this idea in practice. But a possible analogy is: How many tall buildings are around your place, what was their cost, how groundbreaking are they? Chances are, most buildings around you are quite low. Low buildings have a higher overhead in space cost, so especially in denser cities, there is a force to make buildings with more levels.

But after some levels, there are diminishing returns from going even higher, compared to just creating an additional building of the same size. And overhead is increasing. Higher up levels are more costly to construct, and they require a better foundation. We can see that most higher buildings are quite boring: how to construct them is well-understood, there isn't much novelty. There just aren't that many types of buildings that have all these properties: 1) tall/many levels 2) low overall cost of creation and maintenance 3) practical 4) novel.

With software components it's similar. There are a couple of ideas that work well enough such that you can stack them on top of each other (say, CPU code on top of CPUs on top of silicon, userspace I/O on top of filesystems on top of hard drives, TCP sockets on top of network adapters...) which allows you to make things that are well enough understand and robust enough and it's really economical to scale out on top of them.

But also, there isn't much novelty in these abstractions. Don't underestimate the cost in creating a new CPU or a new OS, or new software components, and maintaining them!

When you create your own software abstractions, those just aren't going to be that useful, they are not going to be rock-solid and well tested. They aren't even going to be that stable -- soon a stakeholder might change requirements and you will have to change that component.

So, in software development, it's not like you come up with rock-solid abstractions and combine 5 of those to create something new that solves all your business needs and is understandable and maintainable. The opposite is the case. The general, pre-made things don't quite fit your specific problem. Their intention was not focused to a specific goal. The more of them you combine, the less the solution fits and the less understandable it is and the more junk it contains. Also, combining is not free. You have to add a _lot_ of glue to even make it barely work. The glue itself is a liability.

But OOP, as I take it, is exactly that idea. That you're creating lots of perfect objects with a clear and defined purpose, and a perfect implementation. And you combine them to implement the functional requirements, even though each individual component knows only a small part of them, and is ideally reusable in your next project!

And this idea doesn't work out in practice. When trying to do it that way, we only pretend to abstract, we just pretend to reuse, and in the process we add a lot of unnecessary junk (each object/class has a tendency to be individually perfected and to be extended, often for imaginary requirements). And we add lots of glue and adapters, so the objects can even work together. All this junk makes everything harder and more costly to create.

> structure things as a loosely coupled set of smaller components

Don't build on top of shoddy abstractions. Understand what you _have_ to depend on, and understand the limitations of that. Build as "flat" as possible i.e. don't depend on things you don't understand.

i_am_a_peasant · 2 days ago
> When you create your own software abstractions, those just aren't going to be that useful, they are not going to be rock-solid and well tested. They aren't even going to be that stable -- soon a stakeholder might change requirements and you will have to change that component.

I also think it's about how many people you can get to buy-in on an abstraction. There probably are better ways of doing things than the unix-y way of having an OS, but so much stuff is built with the assumption of a unix-y interface that we just stick with it.

Like why can't I just write a string of text at offset 0x4100000 on my SSD? You could but a file abstraction is a more manageable way of doing it. But there are other manageable ways of doing it right? Why can't I just access my SSD contents like it's one big database? That would work too right? Yeah but we already have the file abstraction.

>But OOP, as I take it, is exactly that idea. That you're creating lots of perfect objects with a clear and defined purpose, and a perfect implementation. And you combine them to implement the functional requirements, even though each individual component knows only a small part of them, and is ideally reusable in your next project!

I think OOP makes sense when you constrain it to a single software component with well defined inputs and outputs. Like I'm sure many GoF-type patterns were used in implementing many STL components in C++. But you don't need to care about what patterns were used to implement anything in <algorithm> or <vector>. you just use these as components to build a larger component. When you don't have well defined components that just plug and play over the same software bus, no matter how good you are in design patterns it's gonna eventually turn into spagetti un-understandable mess.

I'm really liking your writing style by the way, do you have a blog or something?

i_am_a_peasant commented on Surface Tension of Software   iamstelios.com/blog/surfa... · Posted by u/i8s
bpavuk · 2 days ago
I'd personally declare dead everything except 3 and 4 because, unlike the rest, polymorphism is genuinely useful (e.g. Rust traits, Kotlin interfaces)

trivia: Kotlin interfaces were initially called "traits", but with Kotlin M12 release (2015), they renamed it to interfaces because Kotlin traits basically are Java interfaces. [0]

[0]: https://blog.jetbrains.com/kotlin/2015/05/kotlin-m12-is-out/...

i_am_a_peasant · 2 days ago
1 is about encapsulation, that makes it really easy to unit test stuff. Say you need to access a file or a database in your test, you could write an abstraction on top of file or db access and mock that.

2 indeed never made sense to me since once everything is ASM "protected" means nothing, and if you can get a pointer to the right offset you can read "passwords". This claim of enforcing what can and cannot be reached from a subclass to help security never made sense to me.

3 i never liked function overloading, prefer optional arguments with default values.. if you need a function to work with multiple types of one parameter, make it a template and constrain what types can be passed

7 interfaces are a must have for when you want to add tests to a bunch of code that has no tests.

8 rust macros do this, and it's a great way to add functionality to your types without much hassle

9 idk what this is

i_am_a_peasant commented on Surface Tension of Software   iamstelios.com/blog/surfa... · Posted by u/i8s
bpavuk · 2 days ago
this explains virtually everything:

- that's why OOP failed - side effects, software too liquid for its complexity

- that's why functional and generic programming are on their rise - good FP implementations are natively immutable, generic programming makes FP practical.

- that's why Kotlin and Rust are in position to purge Java and C, philosophically speaking - the only things that remain are technical concerns, such as JetBrains' IDEA lock-in (that's basically the only place where you can do proper Kotlin work) as well Rust's "hostility" to other bare-metal languages, embedded performance, and compiler speed.

i_am_a_peasant · 2 days ago
what is it with this take that oop is dead… even the linux kernel heavily uses OOP.

inheritance is what has been changing in scope, where it’s discouraged to base your inheritance structure on your design domain.

i_am_a_peasant commented on Craft software that makes people feel something   rapha.land/craft-software... · Posted by u/lukeio
baxtr · 4 days ago
That is weird enough. But also the fact that he seems to be celebrating that is odd.

Avoiding to spend time with your family shouldn’t be something you enjoy.

i_am_a_peasant · 4 days ago
wanting time away from your loved ones doesn't seem the least bit weird to me.

Like sure you love your wife and kids, but being with them every second of every day is probably too much for most sane people. Especially if you have hobbies that demand a lot of focus time.

i_am_a_peasant commented on Rust in the kernel is no longer experimental   lwn.net/Articles/1049831/... · Posted by u/rascul
scuff3d · 6 days ago
I'm not on the Rust bandwagon, but statements like this make absolutely no sense.

A lot of software was written in C and C++ because they were the only option for decades. If you couldn't afford garbage collection and needed direct control of the hardware there wasn't much of a choice. Had their been "safer" alternatives, it's possible those would have been used instead.

It's only been in the last few years we've seen languages emerge that could actually replace C/C++ with projects like Rust, Zig and Odin. I'm not saying they will, or they should, but just that we actually have alternatives now.

i_am_a_peasant · 6 days ago
you took the ragebait bro :))
i_am_a_peasant commented on Leaving Intel   brendangregg.com/blog//20... · Posted by u/speckx
seabrookmx · 10 days ago
They bought Red Hat, which has OpenShift and all their other "DIY Cloud" bits. This stuff is popular in government or old businesses that may have been slow to (or unable to for regulatory reasons) jump to AWS/GCP etc.

To say nothing of the banks and others still using the IBM big iron.

i_am_a_peasant · 10 days ago
they’ve been partnering with nvidia to build large ML training clusters iirc last time i was in their building at a meetup a few weeks ago
i_am_a_peasant commented on Operating Margins   fi-le.net/margin/... · Posted by u/fi-le
soontimes · a month ago
I like your style - clear, on point, and no attempts to sell me anything. It’s honestly refreshing to read
i_am_a_peasant · a month ago
++1
i_am_a_peasant commented on Radios, how do they work? (2024)   lcamtuf.substack.com/p/ra... · Posted by u/aqrashik
DrAwdeOccarim · 2 months ago
Do yourself a favor and study for both your technician and general at the same time (I’m assuming you live in the US). HF is exponentially more fun than just VHF/UHF.
i_am_a_peasant · 2 months ago
it’s stuff like this that make me wish i lived in the US. i have to memorise a long questionnaire in german if i want to get my license

u/i_am_a_peasant

KarmaCake day218November 21, 2022
About
Embedded guy.

C, C++, ASM, Rust, Python

View Original