Skip to main content
4 events
when toggle format what by license comment
Jun 6, 2021 at 12:34 comment added amon @Wiza While the LSP was popularized in industry as part of the “SOLID principles”, it actually comes from academia as well! Regarding mixing OOP and non-OOP approaches, my first paragraph seems to discourage this, but that's because of the “Tell, Don't Ask” violation explained later. There is no problem with mixing classes and free functions. So yes, do just use functions if that is helpful. Don't stuff code into a class unless it needs to be part of that object.
Jun 6, 2021 at 3:44 comment added Adam Wilson I think the LSP principle was really enlightening. I'm a research student so my background in software design is limited. Mind if I ask, could you use functions that are not part of any class in OOP?
Jun 6, 2021 at 3:02 vote accept Adam Wilson
Jun 4, 2021 at 20:25 history answered amon CC BY-SA 4.0