Skip to content

Add an arity to a function #410

Closed
Closed
@benedekfazekas

Description

@benedekfazekas

By default I define functions as

(defn func [arg]
  body)

Adding an arity to such a function requires

  1. Wrapping the existing arglist and body in parens,
  2. Inserting a set of parens, and
  3. Defining a new arglist.

This is the most tedious refactoring I regularly do, and seems like a good candidate for a clj-refactor operation. I don't have any suggestions for how such an operation ought to work; any automated system ought to beat doing it manually.

Originally crated by @exupero on clj-refactor.el: clojure-emacs/clj-refactor.el#349

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions