‹ BackHN Continuity

Thread

What Zig felt like, coming from Rust

282 points · 351 comments · ksec

  1. hn_submit · · focus · HN ↗
    There will never be a true successor to C since C is "high level assembly." The lack of pointer checking, unsafe casts and non-existent bounds checking aren't an oversight but by design! Assembly doesn't have them so neither does C! There's no reason to whine about it.

    The real problem is that people are using C for the wrong reasons. C is for the development of operating systems and low-level code, not applications.

    Zig is more modern but anything that does even one iota more of hand-holding or has anything that looks like a guardrail fails the test.

    If you want to write applications use Pascal, Java, C#, Swift or Go.

    1. slopinthebag · · focus · HN ↗
      i dunno, people are using rust effectively to build applications too. and apple has started using swift in the kernal.

      i do agree that applications are probably best built in fast garbage collected language. but it also seems like go, java, C#, etc have other downsides that push people towards things like zig or rust even for apps. it also depends on what you mean by "apps". is a server an app? what about an actual native cross-platform desktop application? does go, c#, or java have a good paradigm for that? what if you want to use an oss language not tied to a big tech company? you start running out of suitable languages pretty dang fast.

      you could name any application type and i could probably give you reasons why you might want to build it in a "systems" language instead of a high level one.

Open on Hacker News to reply ↗

Unofficial Hacker News client; not affiliated with Y Combinator.