Skip to content
This repository has been archived by the owner on Nov 14, 2020. It is now read-only.

fn* and multiple arity functions #24

Open
alandipert opened this issue Nov 26, 2013 · 0 comments
Open

fn* and multiple arity functions #24

alandipert opened this issue Nov 26, 2013 · 0 comments
Milestone

Comments

@alandipert
Copy link
Owner

  • fn should be renamed fn*
  • fn* should support multiple, different arity versions of the same function, as in Clojure
  • Possibly: provide an fn that supports sequence destructuring in its argument list
    • Implies a destructuring function we could use elsewhere, like on the left-hand side of let bindings.

It's good because it's a nice way to provide default arguments, particularly when seeding lazy sequences or recursion.

Open questions

  • Perf?
    • An additional special to speed up arity selection of inlines?
      • That way we could call through to the right implementation without consulting an arities -> implementations table.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant