Skip to content

Comment on Keyword Arguments: Ruby, Clojure, Common Lisp

Comments

quote: Positional arguments require mentally lining up the 7th argument in your function call with the 7th argument in the function signature, and so on.

If your function has 7 arguments, consider refactoring

If your refactoring is to make a 7-args function into a builder object (because what you're building actually needs those arguments), you're better off with keyword arguments.

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.