methodical icon indicating copy to clipboard operation
methodical copied to clipboard

Should aux methods be unique per qualifier + dispatch value?

Open camsaul opened this issue 3 years ago • 1 comments

It gets super confusing when you have multiple aux methods with the same dispatch value, and it can lead to weird gotchas if you rename a namespace or remove them. It's also indeterminate which order they're applied in...

I think there are some valid use cases for things like multiple :around :default methods for logging and other things like that. How can we still support that case?

Maybe we should make the unique key something you can optionally supply yourself, and by default it's nil. So if you want to do something weird you can supply a unique key to prevent it from getting stomped on. Altho I'm not sure that would really solve the renaming namespaces issue.

camsaul avatar Aug 18 '22 23:08 camsaul

I like the idea of nil being the default unique key

camsaul avatar Sep 09 '22 16:09 camsaul