Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Zig doesn't have varargs anymore. Instead, it has anonymous structs/arrays/tuples. The second argument to `print` here is expected to be a list of the values referenced by the `{}` placeholders in the string in the first argument.

`.{a, b, c}` is the syntax for an anonymous struct/array/tuple, and a single element still needs to be wrapped in it.



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: