upvote
From https://ziglang.org/intro/overview/

  Zig is also a C compiler

  Here’s an example of Zig building some C code:

  hello.c
  > #include <stdio.h>
  >
  > int main(int argc, char **argv) {
  >   printf("Hello world\n");
  >   return 0;
  > }
  

  $ zig build-exe hello.c -lc
  $ ./hello
  > Hello world
reply
What does that have to do with portability? It doesn’t support a bunch of CPU architectures, the portability metric I care about.
reply
I misread the comment I was replying to, thinking it was about using Zig to port something, when it was actually about porting something that uses Zig.
reply
I/my agent somehow integrated it into a C++ app on Windows. So one way or another, it does work.
reply
Zig is even more portable than C
reply
You’re kidding right? That’s not what the support matrix on the Zig site shows. Plenty of CPU archs in Tier 3/4. No support for Alpha, HPPA, M68K, Sparc, or SuperH.
reply
"portable" and "has ports" mean two different things. there might be targets Zig doesn't have great support for yet but what I meant is that bootstrapping a target to Zig is a simpler endeavor than it is for C
reply
Is it? I think zig use llvm codegen. Once you got llvm for your architecture, you get 99% of modern language
reply