On Monday, 1 September 2025 at 16:26:15 UTC, H. S. Teoh wrote:
OOP is useful for certain classes (ha) of problems, but not all, as the OOP proponents would like you to believe. Some classes of problems are better solved with other means.
Do note that I had to bite the bullet and write an OO File class, just so I could write emulated (but compilation/type compatible) subclasses of File. String- and ubyte[]-based reader/writer instances, specifically. Think Python's StringIO.
It sure made a number of things easy once I could use polymorphism wrt File. I'm very glad that D has classic OO semantics available.
Andy
