Lambdas, you can call them that then, which don't capture context may already be possible, and if not it will be possible in Zig v0.8. In Zig v0.8 they will move to a syntax where functions are always defined anonymous. To refer to them later you need to assign them to a constant.

This is to harmonize the syntax for how e.g. structs are defined in Zig, which is based on the same idea.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store