Earlier quoted context omitted.
D can import C files directly, and can do C-source to D-source translation. D can compile a project with a C and a D source file with: dmd foo.d bar.c ./foo
Do you have to bring up D in every Zig related post? I do like D. I've written a game in it and enjoyed it a lot. I would encourage others to check it out. But it's not a C replacement. BetterC feels like an afterthought. A nice bonus. Not a primary focus. E.g. the language is designed to use exceptions for error handling, so of course there's no feature for BetterC dedicated to error handling. Being a better C is th…
Zig Libc
141–150 of 196 posts
Re: Zig Libc
#142Earlier quoted context omitted.
That's something I've always admired about Zig. A lot of languages claim to be a C replacement, but Zig is the second language I've seen that seemed like it had a reasonable plan to do so at any appreciable scale. The language makes working with the C ABI pretty easy, but it also has a build system that can seamlessly integrate Zig and C together, as well as having a translate-c that actually works shockingly well in…
D can import C files directly, and can do C-source to D-source translation. D can compile a project with a C and a D source file with: dmd foo.d bar.c ./foo
You keep compatibility with C, can tap into its ecosystem, but you are no longer stuck with outdated tooling
D gives you faster iteration, clearer diagnostics, and a generally smoother experience, even if it doesn't go as far as Rust in terms of safety
I wish more languages would follow this strategy, ImportC is great, let's you port things one step at a time, if required/needed
Let's be honest: who wants to write or generate C bindings? And who wants to risk porting robust/tested/maintained C code incorrectly?
Re: Zig Libc
#143Does Zig does have the man power to keep these up to date? I think we either need to make operating systems not in C, or just accept that at some level we rely on C.
Re: Zig Libc
#144Earlier quoted context omitted.
D can import C files directly, and can do C-source to D-source translation. D can compile a project with a C and a D source file with: dmd foo.d bar.c ./foo
Do you have to bring up D in every Zig related post? I do like D. I've written a game in it and enjoyed it a lot. I would encourage others to check it out. But it's not a C replacement. BetterC feels like an afterthought. A nice bonus. Not a primary focus. E.g. the language is designed to use exceptions for error handling, so of course there's no feature for BetterC dedicated to error handling. Being a better C is th…
In this case, however, Walter was not the one that brought up D. He was replying to a comment by someone promoting Zig with the claim that only Zig and C++ have ever had a strategy to replace C. That is objectively false. There's no way to look at what D does in that area and make that sort of claim. Walter and anyone else is right to challenge false statements.
Re: Zig Libc
#145Earlier quoted context omitted.
The very same day I sat at home writing this devlog like a coward, less than five miles away, armed forces who are in my city against the will of our elected officials shot tear gas, unprovoked, at peaceful protestors, including my wife. https://www.kptv.com/2026/01/31/live-labor-unions-rally-marc... This isn't some hypothetical political agenda I'm using my platform to push. There's a nonzero chance I go out there n…
Please stay safe. I can't hold it so had to create an account to share, I'm sorry. I'm one of the minor zig contributors, and I'm reading ziglang blog for the purpose of engagement in software engineering craft. I don't want to see these ICE stuff or whatever else political opinion you or somebody else have. I'm not from US and I barely know what ICE is but you're hating on people (I'm sure you think it's deserved, a…
Meaning: if you can't accept that someone publishing words/code/etc on the web at the same time also offers their own strong opinions (that you directly claim to be hate) about their own such issues, there's plenty of "communities" in which this kind of unempathetic approach to other people and their lives is celebrated and normalized.
If you barely know what ICE is, how can you claim his opinions to be "hate"? How can you claim that Andrew may hate you without thinking you identify with what you understand about ICE?
What ICE does is unmistakenly fascistic and authoritarian, far beyond the powers they have been granted by law and democratic processes. It's utterly disgusting to try and compare protesting and fighting against that with "abolish people with tattoos". ICE is an institution, a government agency among a dozen+ law enforcement agencies in the US. You compare advocating for abolishing it through democratic process (what Andrew expressed) with calling for the murder of many millions of people with a private hobby.
And while Andrew may have some responsibility towards the community he founded; if he has the responsibility to include different political opinions, he most certainly has the responsibility to exclude fascism. Fascism is the destruction of different opinions, it is not a political opinion that can stand among others and be compared on the same basis: that of human rights at the minimum.
Ask yourself and reflect: why does this very simple and inoffensive call by Andrew make you scared, especially if you don't know what ICE is and does? Could you have been influenced into this feeling? It is certainly not a rational reaction to a few characters of text viewed on a screen.
Re: Zig Libc
#146Earlier quoted context omitted.
[flagged]
When people like you finally realize what is happening in this country, I'm ready to quickly forgive and move on so that we can work together to preserve what freedoms we have left. but please hurry... we really need you to pay attention and understand the reality that is upon us.
Re: Zig Libc
#147Earlier quoted context omitted.
Seems like it ought to be able to do inlining and dead code stripping which, I think, wouldn't be viable at link time against optimized static libraries.
It is viable against the IR that static libraries contain when LTO is enabled. LTO essentially means “load the entire compiler backend into the linker and do half of the compilation work at link time”. It’s a great big hack, but it does work.
Re: Zig Libc
#148Earlier quoted context omitted.
Denouncing ICE is not denouncing federal immigration law. The Department of Homeland Security did not exist until 2003. Are you saying that prior to 2003, the US did not enforce federal immigration law?
What's your point? Immigration law existed before 2003 too. It might not have been the DHS or ICE enforcing it, but the concept of illegal aliens wasn't invented in 2003. And yes, I interpret “Abolish ICE” to mean “don't enforce federal immigration law”, because that's what people _usually_ mean when they say “abolish ICE”. Technically, “abolish ICE” could also mean: “abolish ICE and replace it with an even more ruth…