[racket-users] Re: Generics vs. Classes?

2020-11-08 Thread jackh...@gmail.com
The typical use case for classes in Racket is writing GUIs, and that's mostly because the GUI framework is class based. For most other use cases, generics are a better choice than classes. They're simpler and have a less intrusive effect on your API surface. If you don't need to support arbitra

[racket-users] Re: Generics vs. Classes?

2020-11-08 Thread unlimitedscolobb
Thank you for you answer! I'll need to think more about it. The idea of having structs whose fields contain functions has never occurred to me, but it may actually fit my relatively simple use case (and the planned migration to Typed Racket). - Sergiu On Sunday, November 8, 2020 at 8:22:16 PM