this post was submitted on 03 Oct 2024
40 points (87.0% liked)

Programming

17416 readers
86 users here now

Welcome to the main community in programming.dev! Feel free to post anything relating to programming here!

Cross posting is strongly encouraged in the instance. If you feel your post or another person's post makes sense in another community cross post into it.

Hope you enjoy the instance!

Rules

Rules

  • Follow the programming.dev instance rules
  • Keep content related to programming in some way
  • If you're posting long videos try to add in some form of tldr for those who don't want to watch videos

Wormhole

Follow the wormhole through a path of communities !webdev@programming.dev



founded 1 year ago
MODERATORS
 

Zig vs Rust. Which one is going to be future?

I think about pros and cons and what to choose for the second (modern) language in addition to C.

@programming@programming.dev

you are viewing a single comment's thread
view the rest of the comments
[–] mox@lemmy.sdf.org 6 points 1 month ago (1 children)

It's too early to tell.

Rust has a killer feature and a tonne of buzz, but poor ergonomics.

Zig is developing into simple elegance and wonderful interop, but has more work to do before it will be widely usable.

It's entirely possible that ideas and lessons taken from them will inspire another language that ends up eclipsing them both.

[–] arendjr@programming.dev 13 points 1 month ago* (last edited 1 month ago) (1 children)

I would say at this point in time it’s clearly decided that Rust will be part of the future. Maybe there’s a meaningful place for Zig too, but that’s the only part that’s too early to tell.

If you think Zig still has a chance at overtaking Rust though, that’s very much wishful thinking. Zig isn’t memory safe, so any areas where security is paramount are out of reach for it. The industry isn’t going back in that direction.

I actually think Zig might still have a chance in game development, and maybe in specialized areas where Rust’s borrow checker cannot really help anyway, such as JIT compilers.

[–] mox@lemmy.sdf.org -3 points 1 month ago (1 children)

Okay, but...

it’s clearly decided that Rust will be part of the future.

That's not what OP asked.

If you think Zig still has a chance at overtaking Rust though, that’s very much wishful thinking.

That's not what I said.

[–] arendjr@programming.dev 10 points 1 month ago* (last edited 1 month ago) (1 children)

No, OP asked for a black and white winner. I was elaborating because I don’t think it’s that black and white, but if you want a singular answer I think it should be clear: Rust.

[–] mox@lemmy.sdf.org 1 points 1 month ago* (last edited 1 month ago)

I see. You replied to me, though, with commentary that doesn't fit the question I was answering or the thoughts I was expressing. Don't you think it would have made more sense as a reply to OP?