Live data from Hacker News

Zig, the Small Language

zserge.com

1–10 of 429 posts

Re: Zig, the Small Language

#2
I maybe overstating it, but another contributing factor to its growing popularity may be the documentation. It is really nice and well presented. Reminds me of how the rust book also welcomed you to explore the language.

Re: Zig, the Small Language

#3

I maybe overstating it, but another contributing factor to its growing popularity may be the documentation. It is really nice and well presented. Reminds me of how the rust book also welcomed you to explore the language.

Zig has good docs now? Nice. Last I looked Zig had some of the worst docs I'd seen to the point where I just looked at the std sources and eventually just gave up

Re: Zig, the Small Language

#4
I tried Zig recently but I found the unsilenceable lints to be a huge productivity killer. I actually posted a link to the GitHub issue this morning. https://news.ycombinator.com/item?id=32751317

This makes a normal workflow with `watchexec zig test` basically impossible, since before I can even run the tests I have to spend time hunting down which variables are used/unused at the moment and (un)commenting them. And it seems like they're planning to double down on this by making you adjust even more trivial things like public/private and var/const before it will even compile your code. https://github.com/ziglang/zig/issues/335 https://github.com/ziglang/zig/issues/224

Maybe I'm a bad developer, but my code is never perfect the first time around. I always spend time experimenting and refining my designs. I want to find a design that works, and only then spend time polishing and prettifying before I git push.

I do understand the reasoning (they don't want people committing poor quality code), but this implementation just seems completely backwards to me. It breaks the natural order. It's like saying we won't let you ctrl+s until your tests pass to make sure you don't commit broken code. Stop nannying me and let me get my work done!

Re: Zig, the Small Language

#5

I tried Zig recently but I found the unsilenceable lints to be a huge productivity killer. I actually posted a link to the GitHub issue this morning. https://news.ycombinator.com/item?id=32751317 This makes a normal workflow with `watchexec zig test` basically impossible, since before I can even run the tests I have to spend time hunting down which variables are used/unused at the moment and (un)commenting them. And…

You can always do ' _ = your_varible', don't have to comment individuals

Re: Zig, the Small Language

#7
Zig indeed is pretty nice, i just wish it had some more sweet to it

- my math type with + - * / overloads

- simpler way to fill an array, i can never remember the syntax, it doesn't feel natural `[_]u8{0} * 10;`

- smarter type system, i am tired of casting everything twice

A good language is not a language set in stone, a good language is a language that doesn't make me feel like i have to suffer because they made a stupid decision years ago and they refuse to make it better

Re: Zig, the Small Language

#8
post #5

I tried Zig recently but I found the unsilenceable lints to be a huge productivity killer. I actually posted a link to the GitHub issue this morning. https://news.ycombinator.com/item?id=32751317 This makes a normal workflow with `watchexec zig test` basically impossible, since before I can even run the tests I have to spend time hunting down which variables are used/unused at the moment and (un)commenting them. And…

You can always do ' _ = your_varible', don't have to comment individuals

That was the first suggestion that Kelley posted on the issue and judging by the reactions people weren’t happy with it.

Re: Zig, the Small Language

#9
post #5

I tried Zig recently but I found the unsilenceable lints to be a huge productivity killer. I actually posted a link to the GitHub issue this morning. https://news.ycombinator.com/item?id=32751317 This makes a normal workflow with `watchexec zig test` basically impossible, since before I can even run the tests I have to spend time hunting down which variables are used/unused at the moment and (un)commenting them. And…

You can always do ' _ = your_varible', don't have to comment individuals

That makes unused variables "used", which defeats the point of the check.

Re: Zig, the Small Language

#10
post #5

Earlier quoted context omitted.

You can always do ' _ = your_varible', don't have to comment individuals

That was the first suggestion that Kelley posted on the issue and judging by the reactions people weren’t happy with it.

Completely unsurprisingly. "Add useless garbage to work around the stupid decisions we impose on you" is not very appreciated.
Post reply on HN