Zig 0.4.0 Released
ziglang.org
Zig 0.4.0 Released
1–10 of 141 posts
Re: Zig 0.4.0 Released
#2Re: Zig 0.4.0 Released
#3I love seeing all the progress with Zig, V, Muon, and Rust. All these languages are potentially-better systems languages than C/C++, with better safety, better definitions, and better semantics. Zig has an explicit goal to be better than C and to replace it.
Re: Zig 0.4.0 Released
#4Re: Zig 0.4.0 Released
#5Zig claims very proudly it is about clarity but shortly into reading through the documentation I already found this extremely surprising:
"Multiline string literals have no escapes and can span across multiple lines. To start a multiline string literal, use the \\ token. Just like a comment, the string literal goes until the end of the line."
I could not have tried to make a more confusing token for multiline string literals if I tried. The difference between a string literal and comments is literally whether or not the lines are preceded by an open =.
Re: Zig 0.4.0 Released
#6It's been a real pleasure seeing Zig grow, hopefully it can fill that niche for a high performance, portable, modern language that isn't filled with OOP cruft
Re: Zig 0.4.0 Released
#7Edit: Just confused myself, comments are // and multiline literals are \\. Thanks to laszlokorte for catching my mistake! Zig claims very proudly it is about clarity but shortly into reading through the documentation I already found this extremely surprising: "Multiline string literals have no escapes and can span across multiple lines. To start a multiline string literal, use the \\ token. Just like a comment, the s…
Well comments use forward slash (//) and string literals use backslash (\\)
Re: Zig 0.4.0 Released
#8Edit: Just confused myself, comments are // and multiline literals are \\. Thanks to laszlokorte for catching my mistake! Zig claims very proudly it is about clarity but shortly into reading through the documentation I already found this extremely surprising: "Multiline string literals have no escapes and can span across multiple lines. To start a multiline string literal, use the \\ token. Just like a comment, the s…
Re: Zig 0.4.0 Released
#9Edit: Just confused myself, comments are // and multiline literals are \\. Thanks to laszlokorte for catching my mistake! Zig claims very proudly it is about clarity but shortly into reading through the documentation I already found this extremely surprising: "Multiline string literals have no escapes and can span across multiple lines. To start a multiline string literal, use the \\ token. Just like a comment, the s…
Python has an even closer relationship between comments and string literals: its multiline comments are just string literals that get never used.
Re: Zig 0.4.0 Released
#10Edit: Just confused myself, comments are // and multiline literals are \\. Thanks to laszlokorte for catching my mistake! Zig claims very proudly it is about clarity but shortly into reading through the documentation I already found this extremely surprising: "Multiline string literals have no escapes and can span across multiple lines. To start a multiline string literal, use the \\ token. Just like a comment, the s…
> The difference between a string literal and comments is literally whether or not the lines are preceded by an open =. Well comments use forward slash (//) and string literals use backslash (\\)