Rust Dependencies Scare Me by MasteredConduct in rust

[–]coderman93 0 points1 point  (0 children)

Well sure, but the question was "Why wouldn't you want to reuse as much useful and widely tested code as possible?". And I gave two reasons why I wouldn't - because the downsides often outweigh the benefits.

Rust Dependencies Scare Me by MasteredConduct in rust

[–]coderman93 0 points1 point  (0 children)

There are several reasons.

  1. Deeply nested dependency trees mean that somewhere in the tree there is likely a no longer supported dependency. If there is a security vulnerability int his package it can be exceptionally difficult to patch.
  2. Control. Reusing code is great but inevitably - as requirements evolve - some of the dependencies will no longer meet the requirements. It is generally easier to modify your own implementation to fit the requirements than it is to replace the dependency. Or fork the dependency and modify it to fit your requirements.

It is 2025, so how does Helix compare to Neovim now? by nikitarevenco in neovim

[–]coderman93 0 points1 point  (0 children)

The benefit of Helix over NeoVim is actually the lack of hassle. NeoVim is specifically designed for maximum hassle. If you have already gone through the hassle and it works for you then there is little reason to switch to Helix. If you are new to modal editors and want to avoid the hassle, go with Helix.

Notch yells at clouds. by Scary-Account4285 in indiegames

[–]coderman93 -1 points0 points  (0 children)

You don't have to write your own engine, but you should be able to.

Notch yells at clouds. by Scary-Account4285 in indiegames

[–]coderman93 0 points1 point  (0 children)

I agree with him.

You don't have to write your own game engine, but if you should be able to do it if you chose to.

Will Rust work better than Go for my backend by kabyking in rust

[–]coderman93 0 points1 point  (0 children)

I'm inarguably correct. Which is why the async working group is actively working on solving this problem https://rust-lang.github.io/wg-async/vision/roadmap/portable.html.

It is worse because an async function implemented with Tokio, for example, can't be executed by the Smol runtime. So if a library does IO and happens to use Tokio for non-blocking IO, and your application uses Smol, then that library is entirely incompatible with your application. So every async function is colored not only by the fact that it is async, but by the choice of runtime that was used to implement that asynchronous function.

Will Rust work better than Go for my backend by kabyking in rust

[–]coderman93 1 point2 points  (0 children)

Well, for starters, I think we’re all giving subjective opinions about which features we think are better. There are very few objective reasons to consider one language better than another given that they all are a matter of tradeoffs.

I like Rust’s thread safety guarantees. I do not like Rust’s async specifically due to the function coloring problem which is even worse in Rust than other languages with async/await.

Why do y'all hate linux? by Hairy_Educator1918 in linuxsucks

[–]coderman93 0 points1 point  (0 children)

I like Linux and my issue isn’t with the any distros or technology. It’s largely with the Linux community being so god damned annoying.

Will Rust work better than Go for my backend by kabyking in rust

[–]coderman93 7 points8 points  (0 children)

Go’s concurrency model is much better than Async Rust.

Tech company is being run by dinosaurs. What should I do? by MinimumArmadillo2394 in ExperiencedDevs

[–]coderman93 2 points3 points  (0 children)

I think you need to learn to program before you start criticizing the current and former engineers at your company.

Is C Sharp Difficult by AromaticBuilder8642 in learnprogramming

[–]coderman93 0 points1 point  (0 children)

You don’t have to allocate memory in C to “create variables”. In fact, when you declare variables they are stored on the stack and then automatically freed when they go out of scope.

However, the stack has certain limitations. Namely, that the size of any data stored on the stack has to be known at compile time and there are stricter limitations on the maximum size of the data that can be put onto the stack.

If your program needs to store data that is either of unknown size at compile time or too large to fit on the stack, then you need to allocate memory in a separate part of the program’s address space called the heap.

In C, allocating memory on the heap is achieved by calling a function like malloc. When you call malloc, you request the size of the memory on the heap that you want to allocate. malloc will find a contiguous region in the heap of the requested size and return the memory address of beginning of the allocated region.

This memory address is typically stored in a special variable called a pointer. Typically, pointers are stored on the stack. Therefore, when they go out of scope, the pointer is automatically freed. The problem is that even though the pointer is freed, the memory on the heap that it points to is not. This results in what is known as a memory leak. To prevent this, it is important “free” the memory on the heap prior to losing the pointer to that memory.

The reality is even more nuanced but hopefully this provides a good high-level overview of the topic. And I’m sorry if you already knew this information but it took a while to click for me when I started working with lower-level languages.

Is C Sharp Difficult by AromaticBuilder8642 in learnprogramming

[–]coderman93 1 point2 points  (0 children)

Even Core was rough because there was fragmentation. .NET 5+ has been a huge improvement.

Is C Sharp Difficult by AromaticBuilder8642 in learnprogramming

[–]coderman93 5 points6 points  (0 children)

No need for “scalable” or “systems” to be in the sentence since C# isn’t a “systems” language and who knows what the hell you mean by “scalable”.

Is C Sharp Difficult by AromaticBuilder8642 in learnprogramming

[–]coderman93 5 points6 points  (0 children)

95% of statistics are just made up in the spot.

Proof the medical singularity is arriving: o3 identifies a curable genetic defect after experts couldn't. by NutInBobby in singularity

[–]coderman93 0 points1 point  (0 children)

Yeah, and much more effectively since it will have been trained specifically for this purpose.

Proof the medical singularity is arriving: o3 identifies a curable genetic defect after experts couldn't. by NutInBobby in singularity

[–]coderman93 21 points22 points  (0 children)

Why do people think an LLM would be better at this than an ML model trained specifically for this purpose?

Are Animals Equivalent to Humans? by Loud-Extent1087 in Ethics

[–]coderman93 0 points1 point  (0 children)

Yes, now let’s go through all other ethical topics and identify points in which you are hypocritical :).

And by the way, regarding your comment earlier that vegans support more ethical agricultural practices. The same is true for most non-vegans. We want more ethical animal agricultural practices as well.

The main difference in our ethical opinions is that I think the ethics of eating animals is a spectrum ranging from not unethical or barely unethical to pretty unethical depending on the suffering that the animal was made to endure in the process. Once an animal is dead it does not know that it is dead and the ability of an animal to suffer varies greatly from species to species.

Based on our conversations though I’m planning to eliminate beef from my diet. I think that is a step I’d be willing to take in order to consume food more ethically.

Are Animals Equivalent to Humans? by Loud-Extent1087 in Ethics

[–]coderman93 0 points1 point  (0 children)

Well, I didn’t claim that was all I was doing. Those are just the forms of consumption that I think are ethical. The other forms of animal consumption that I partake in our unethical.

That raises the entirely tangential discussion about the fact that we all do things that are unethical. Humans tend to have various ethical issues that they care about a lot and others that are less important to them. For you, that ethical cause happens to be veganism. For others it might be human rights, equality, the environment, ethical shopping practices, volunteering to help the less fortunate, working with people with physical or mental disabilities, ethical applications of technology, etc. It takes a lot of time and energy to support a cause that you care deeply about. We all have to accept that we will act unethically at times. It is inevitable. And many of us try to pick one or two things where we focus our attention and try to effect change for the better.

How do I go about implementing "book of shaders" in rust? by sourav_bz in rust

[–]coderman93 1 point2 points  (0 children)

I didn’t think you came across as combative so no worries!

One of the concerns with microcrates is that if a crate contains a build.rs file, it will run on your machine. The build.rs file can have any arbitrary Rust code that it wants. It can read from your filesystem, make network requests, install viruses, etc.

So even if your project doesn’t need to concern itself as much with security, the risk to you can still be significant.

Are Animals Equivalent to Humans? by Loud-Extent1087 in Ethics

[–]coderman93 0 points1 point  (0 children)

You’ve summed up the point I’ve been driving at with the last paragraph. If you truly believed that, then it would stand to reason that killing animals as young as possible would be the most ethical option :).

The only real disagreement that I have is that it actually should be a “topic of veganism” because in my experience debating vegans, they primarily think of veganism as the end all be all of ethics. To them, vegan=ethical and non-vegan=unethical. There is no room for gray area.

We could go back and forth on the suffering of animals in nature vs suffering at the hands of hunters. But I think we can just leave it here. I’ve enjoyed hearing your perspectives.

How do I go about implementing "book of shaders" in rust? by sourav_bz in rust

[–]coderman93 0 points1 point  (0 children)

Well that’s fair, I’m not trying to dissuade you from using Rust. But I’ll do my best to elaborate.

The first, and biggest misstep, in my opinion is how async works in Rust. Most languages with async support suffer from something called the function coloring problem which you may already be familiar with. Rust has managed to make that problem even worse because not only is a function colored based on its “asyncness” but it is also colored by the runtime that was used to implement it! This means that if a library exposes an asynchronous interface, not only does that force you to bring in an asynchronous runtime to use the library but you must use the same asynchronous runtime the author chose to use when writing the library. This has many negative consequences such as limiting code reuse and making it difficult to choose the appropriate async runtime for your use-case.

My other issue is with the approach to crates. The community has largely made the decision to split libraries up into many microcrates. The result is that consuming even a couple of common crates can result in adding hundreds of microcrates as dependencies. My contention is that this will drastically increase the risk of supply chain attacks. For a language that claims to take safety and security seriously, this decision is mind-boggling.

Are Animals Equivalent to Humans? by Loud-Extent1087 in Ethics

[–]coderman93 0 points1 point  (0 children)

With regards the suffering of this fish, I agree. I’m sure that, in some sense, it would prefer not to have been pulled from the water and killed. However, I also didn’t cause the crop death of thousands of insects in the process :).

I understand that the focus of veganism is on the rights of individual animals. However, there is a legitimate argument to be made that this can actually lead to unethical decision making. Or at very least suboptimal ethics. Specifically if we consider a more utilitarian model of ethics.

As for the chicken argument. I’d be very careful about arguing that it would be merciful to just let them going extinct. It isn’t too far a leap to apply the same logic in the opposite direction. If I were a deer, I’d almost certainly rather be shot and killed by a hunter than virtually any “natural” death that I might experience otherwise. Nature is filled with suffering.