News for hackers. Stuff that matters.
Re:Zinc, a systems programming language prototype by fc417fc802 on Wednesday March 12, 2025 @10:17PM (#43349781)
Indeed, that makes it not a systems language by any definition I am familiar with.

> Reasonable C interop, and probably, initial compilation to C.

How do you achieve "reasonable C interop" without pointers, I wonder?

Re:Zinc, a systems programming language prototype by apgwoz on Wednesday March 12, 2025 @10:48PM (#43349938)
You cast integers to pointers and play with fire, of course!
Re:Zinc, a systems programming language prototype by fc417fc802 on Wednesday March 12, 2025 @11:54PM (#43350232)
Void*? Int. Char**? Also an Int. I take it back. This is true systems programming - the same type safety that raw assembly is known for.
Re:Zinc, a systems programming language prototype by pjmlp on Thursday March 13, 2025 @08:08AM (#43352456)
Ironically Assembly is safer than C and languages that descend from it, because although CPUs might have undefined behaviour when given undocumented opcodes, or operation modes, the CPU doesn't rewrite your code without telling you about it.
Re:Zinc, a systems programming language prototype by AnimalMuppet on Thursday March 13, 2025 @10:01AM (#43353460)
That's "safer" only against a very specific and limited set of dangers. But it opens the door to other dangers.
Re:Zinc, a systems programming language prototype by fithisux on Thursday March 13, 2025 @04:33PM (#43356977)
Yes it is. Great comment.
Re:Zinc, a systems programming language prototype by pjmlp on Thursday March 13, 2025 @08:06AM (#43352437)
Naturally with PEEK and POKE.