4 ms·
I also kinda like it , but I believe this implies that function types either can't be first class values or that parsing needs full type information because oth
by myrmidon 4y ago
I also kinda like it , but I believe this implies that function types either can't be first class values or that parsing needs full type information because otherwise you couldn't distinguish between single and chained calls-- or am I missing something?
- samatman 4y agoI wouldn't call C functions first class either, it's a fuzzy term though. Function pointers, yes, and that's another place where it's pretty cool that there are two distinct parameter lists. I just found Blech this morning so I don't know how it deals with function pointers. Competently, I'm guessing.
- samatman 4y agoCompletely missed your point in a sibling reply, let me try again. Returning a function pointer should be ok, chain syntax is a sugaring which is probably not high-payoff in an embedded language. So would explicitly capture the pointer as a stack variable and then use it, three parentheses would be illegal instead of ambiguous. Seems reasonable to me.