Hacker News new | ask | show | jobs
by zamubafoo 2413 days ago
It might just be me, but isn't that just how you name your attributes within the function definition? I don't see how that would help disambiguate without have to look at the function definition at the very least.
1 comments

The point is it's a new way of looking at arguments (in this toy example). In Latin, the order of the nouns typically does not matter. Their role in the statement is unambiguously determined by their declension.

So if you wrote a library with the verb "bite", you wouldn't specify that the first bites the second, or the first was bitten by the second. Those are ambiguous, because they're you're choice as a developer. Rather, you'd specify that the noun in the subject case bites the noun in the object case. That's unambigious in all declined languages.

So, as a reader of someone else's code, I can see immediately that `bite(boy-um, dog)` -- in my fake Latin where "um" denotes the object (cf. "Puer - Puerum") -- that the boy was bitten by the dog. I don't need to look up any documentation or look at how the variables are named in a third-party library.

Again, of course this case is a toy example. The article is more in-depth.