logoalt Hacker News

nromiunlast Sunday at 4:43 PM2 repliesview on HN

I like Zig as well, but I won't call its syntax lovely. Go shows you can do pretty well without ; for line breaks, without : for variable types etc.

But sure, if you only compare it with Rust, it is a big improvement.


Replies

nine_klast Sunday at 4:54 PM

I personally find Go's bare syntax harder to parse when reading, and I spend more time reading code than typing it (even while writing).

An excessively terse syntax becomes very unforgiving, when a typo is not noticed by the compiler / language server, but results in another syntactically correct but unexpected program, or registers as a cryptic error much farther downstream. Cases in point: CoffeeScript, J.

show 1 reply
IshKebablast Sunday at 5:30 PM

Removing stuff doesn't necessarily make the syntax better, otherwise we'd all use Lisp and the space bar wouldn't exist: https://en.wikipedia.org/wiki/Scriptio_continua

show 1 reply