Skip to content

Clarify meaning of extra :()= in expression #1234

Closed Answered by DyXel
jamadagni asked this question in Q&A
Discussion options

You must be logged in to vote

func is a deduced thing equal to (:= or : _ =), then you are declaring an unnamed function by writing :() = { ... } which is assigned to func. The equivalent would be to just write func: () = { ... }, but keep in mind that today it is not yet possible to write regular functions within another function body.

Replies: 3 comments 3 replies

Comment options

You must be logged in to vote
2 replies
@jamadagni
Comment options

@DyXel
Comment options

Answer selected by jamadagni
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
1 reply
@jamadagni
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
4 participants