Hacker News new | past | comments | ask | show | jobs | submit login

But named-args in Python are also syntactic sugar for passing dictionaries around. Object-unpacking of the the kind described here is another one.



Syntactic sugar is the important part here.

You can always pass an object and handle defaults and default merging within the function body, sure.

I use JavaScript a ton and I do love object spread and array destructuring. But writing function signatures is still very clumsy.




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

Search: