I have a question: I can extend the standard library by inserting methods into other namespaces. E.g.:
struct Fun end function Base.close(fun::Fun) print("Fun can't be closed") end
Is it generally a good idea or a bad idea to extend functions this way?
I come from C++, where putting anything in the STL’s namespace is considered a Very Bad Thing. So I expect “no,” but I’m in a discussion elsewhere with somebody who thinks it’s the right thing to do. Is there a stylistic convention or technical reason to do things one way or the other?