Fork me on GitHub

It seems to me that update-in is broken for empty paths in the following way: - (update-in {1 2} [] (constantly 3)) currently returns {1 2 nil 3} - I would expect it to return the number 3 Is this by design? If not, is this something that could still be changed?


if I recall correctly, the answer I have seen given in the past with regards to this is that the behavior of update-in with an empty path is undefined


if you search jira for update-in there is a whole list of stuff, might be a good place to start reading


ah thanks. yeah, sorry, was a bit lazy with my question


as much as a loath style guides and the like, it might be nice to add some stuff about record usage to like "use the factory functions" and "never import the record class unless you also require the namespace where it is defined"


for the last one you could use :load-ns true when defining your record