Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

By putting it in a module, you avoid having to add the method to every single class.


By putting it on Object (this is my ruby side speaking) you avoid the same thing.


Hmm, no. You have to add __copy__ and/or __deepcopy__ to every class.


Only to override the default implementation.




Consider applying for YC's Summer 2026 batch! Applications are open till May 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: