Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

4
  • 1
    Protocol methods cause functions of the same name to be defined in the current namespace. When you call a protocol method from some Clojure code, what you're actually calling is a generated function that looks up and dispatches to the appropriate implementation. Commented Apr 23, 2014 at 19:37
  • Thanks in advance Alex, but how would you solve this case "current namespace conflict"? Commented Apr 23, 2014 at 20:34
  • 1
    Same as you would any other namespace conflict, as described in the answers below. The fact that it happens to be a protocol method causing the conflict is of little importance. Commented Apr 23, 2014 at 21:02
  • Thanks @Alex I've published below the 2 working solutions for this case, with multimethods and extending protocol, both changing the function name Commented Apr 24, 2014 at 11:04