Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fate of insert and delete after these functions get into Base #116

Open
aplavin opened this issue Aug 24, 2023 · 0 comments
Open

fate of insert and delete after these functions get into Base #116

aplavin opened this issue Aug 24, 2023 · 0 comments

Comments

@aplavin
Copy link
Member

aplavin commented Aug 24, 2023

Assuming JuliaLang/julia#46453 gets merged at some point, Base will export functions insert and delete. This raises the question of what to do with Accessors.insert and delete? At least three possible alternatives:

  • Keep as-is: separate functions with the same name. They'll need to be qualified then, and writing Accessors.delete(...) is pretty verbose.
  • Add new methods to Base functions. The current convenience remains, with minor type piracy like delete(_, ::ComposedFunction). Hard to imagine something other than optics library defining this method anyway :)
  • Change their names to something different. Hard to come up with similarly clean names. odelete?

I wonder if I'm missing others or their +/-.

@aplavin aplavin changed the title insert and delete after these functions get into Base fate of insert and delete after these functions get into Base Aug 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant