Live data from Hacker News

Maintain It with Zig

kristoff.it

241–250 of 286 posts

Re: Maintain It with Zig

#241
post #180

Earlier quoted context omitted.

Zig has been on my radar precisely because of Andrew Kelley's vision. I wrote about cross-compiling to a raspberry-pi and writing a barebones driver for an OLED display[^1] That was a lot of fun despite the fact the code was incredibly basic. The interop with C was effortless. [^1] https://www.kamelasa.dev/posts/gettin-ziggy-with-it-pi-zero....

Yeah I watched a couple of his talks, enjoyed every word. There is another interesting language (won't mention the name) but the creator won't let the public in and has a superiority complex, turned me off instantly. I believe Zig will blow up just because of the strong vision but without being a dick about it. It's next on my list for sure.

Ahh you mean Elm, by any chance?

I feel Elm's growth has been stunted because the creator is actively hostile with whoever disagrees with him. I remember the infamous "leaving elm" post which was handled so poorly by Elm's author.

If they had handled it well, elm would have definitely seen a large uptick in adoption

Re: Maintain It with Zig

#242
post #241

Earlier quoted context omitted.

Yeah I watched a couple of his talks, enjoyed every word. There is another interesting language (won't mention the name) but the creator won't let the public in and has a superiority complex, turned me off instantly. I believe Zig will blow up just because of the strong vision but without being a dick about it. It's next on my list for sure.

Ahh you mean Elm, by any chance? I feel Elm's growth has been stunted because the creator is actively hostile with whoever disagrees with him. I remember the infamous "leaving elm" post which was handled so poorly by Elm's author. If they had handled it well, elm would have definitely seen a large uptick in adoption

Nah another one, don't want to bad mouth it because I still hope the language does well. There's actually a bunch that could fit into the category.

Re: Maintain It with Zig

#243
post #6

Zig is a very interesting language. You are able to do thing that would require wizard level skills in C with simple plain language construct. Like serializing/deserializing an enum variants over the wire for example in the most efficient way (look at std.json.{parser, stringify} [0]). > soon we’ll also have a package manager This. If they succeed to do this (and I have my doubts) it will be a paradigm shift for low-…

> Let's hope this is not vaporware. I sincerely approve of the skepticism. I can assure you there is already a very large fire under my ass to get this shipped. To provide some more context, here is a snippet from the latest release notes[0]: > Having a package manager built into the Zig compiler is a long-anticipated feature. Zig 0.8.0 does not have this feature. > If the package manager works well, people will use…

With the self hosted compiler, is there a plan to provably determine the binary remains free from viruses?

How will you verify the chain of trust?

Re: Maintain It with Zig

#244
post #241

Earlier quoted context omitted.

Yeah I watched a couple of his talks, enjoyed every word. There is another interesting language (won't mention the name) but the creator won't let the public in and has a superiority complex, turned me off instantly. I believe Zig will blow up just because of the strong vision but without being a dick about it. It's next on my list for sure.

Ahh you mean Elm, by any chance? I feel Elm's growth has been stunted because the creator is actively hostile with whoever disagrees with him. I remember the infamous "leaving elm" post which was handled so poorly by Elm's author. If they had handled it well, elm would have definitely seen a large uptick in adoption

Parent poster 99% is referring to Jai. I'm of the same general opinion: interesting language, I've spent a lot of time watching jblow talk about it on Twitch, and it would be nice if it succeeded, unfortunately I have my doubts given jblow's attitude both in terms of external communication and within the development team [0].

[0] https://www.youtube.com/watch?v=Nutcb6ao0mc&t=4508s

Re: Maintain It with Zig

#245

Earlier quoted context omitted.

Vlang started as a closed source project with a lot of lofty claims that fell apart quickly once the project was actually opened up. Combined with all the delays and broken delivery promises leading up to that, it gave people a poor impression of the project. With that said, I've heard the situation has improved since then.

Can you list any claims that fell apart? For example, one of the biggest claims has always been fast compilation. Here's V compiling itself in 0.3 seconds: https://www.youtube.com/watch?v=pvP6wmcl_Sc V was also self hosted (written in V) from the start, which says a lot about the maturity of the language. > Combined with all the delays There were no delays. The project was announced to be released in June, and it was…

> Can you list any claims that fell apart?

On home page, the very first claim:

> No null

However V has `nil` or any reference can be initialized to `0`. How is then claiming `no null` not false?

Re: Maintain It with Zig

#246

Earlier quoted context omitted.

I mean, C11 also has generics, but I would really suggest not using it X). See https://en.cppreference.com/w/c/language/generic Of couse, it's a much less powerful feature, there's nothing like interfaces or stuff, just a way to "overload" based on the type.

Thank you. I had no idea that you could do such a thing in C11 preprocessor

_Generic() is not a preprocessor feature, but a "real" language feature (I was confused too when I saw it first though).

The only preprocessor part in the example is mapping the function-like macro 'cbrt(X)' to the language keyword '_Generic(X)'.

Re: Maintain It with Zig

#247
post #96
post #15

Earlier quoted context omitted.

I think that's correct with some overlap, yes. Zig's explicit goal - as stated by the creator - is to replace C. Nothing more, nothing less. I feel like Rust wants to replace C but it also wants to replace C++. And given the complexity difference between the two languages, that means that Rust will end up closer to C++ than to C. So there's some overlap based on how Rust positions itself, but not based on how Zig pos…

We already have c/c++ as low level bases, now zig/rust are coming for the throne, I really hope contenders dont keep spawning like rabbits. If everyone got behind a smaller # of initiatives the worlds codebase would be simpler going forward? I'm imaging some poor software engineer in 2065, having to maintain an enterprise legacy stack... levels of FORTRAN/COBOL->C->C++->ZIG->RUST->PERL->PYTHON.... all the way up....J…

> I really hope contenders dont keep spawning like rabbits

I do, because that would mean that more attention must be paid to make languages work together, instead of each language ecosystem becoming its own little island. Maintaining a project built from a dozen languages (where each language does one thing well) should be just as simple as maintaining a mono-language project.

Re: Maintain It with Zig

#248

Agreed for sure that working with C and C++ is the only way forward for systems languages. Rust's expression of this is the zero-cost C FFI, using native platform tooling, and stuff like that. Rust was never about re-writing the world, after all, its reason for existing was to eventually improve Firefox. The very first presentation about Rust ( http://venge.net/graydon/talks/intro-talk-2.pdf ) says "We are not “rewri…

Since Rust is built on top of LLVM, what's preventing it from "just" adding the Clang C/C++/ObjC frontends into the Rust compiler, and create cargo packages with cross-platform C/C++/ObjC headers and runtimes? This would make cross-compilation and C/C++/ObjC integration just as easy as with Zig (and without requiring any external C toolchain, which is the most important point).

I guess the other (simpler) alternative is to wrap Zig into a Cargo package, similar to this:

https://pypi.org/project/ziglang/

Re: Maintain It with Zig

#249
post #113
post #96

Earlier quoted context omitted.

We already have c/c++ as low level bases, now zig/rust are coming for the throne, I really hope contenders dont keep spawning like rabbits. If everyone got behind a smaller # of initiatives the worlds codebase would be simpler going forward? I'm imaging some poor software engineer in 2065, having to maintain an enterprise legacy stack... levels of FORTRAN/COBOL->C->C++->ZIG->RUST->PERL->PYTHON.... all the way up....J…

> I'm imaging some poor software engineer in 2065, having to maintain an enterprise legacy stack... levels of FORTRAN/COBOL->C->C++->ZIG->RUST->PERL->PYTHON.... all the way up....JS..etc.. I have good news and bad news: That programmer will not know any of those languages, as they will just program in English and GPT-3000 will convert it into code.

This has been attempted many times in the last century but never happened, I think it's quite safe to say that this also won't happen in the next century.

Re: Maintain It with Zig

#250

Earlier quoted context omitted.

100% of platforms that Zig & Rust run on already have a C compiler installed, though. A c compiler being present is the baseline assumption. If Zig existed in places C doesn't and I wanted to write C for that platform then having Zig CC would be an advantage. But such a situation doesn't currently exist and seems unlikely to ever exist? Especially in the context of a library/module porting to Zig or Rust piecemeal, t…

You might not be aware that Zig runs perfectly fine on Microsoft Windows, without MSVC installed. Consider also that installing Zig on Windows is a matter of unpacking a 40 MiB .zip file, whereas installing MSVC on Windows requires downloading something like 8 GiB, being an administrator (!!), and restarting the computer twice.

[deleted]
Post reply on HN