Hacker News new | past | comments | ask | show | jobs | submit login

There's a lot of non-MVC, non-OO "good" code out there. An immediate example is the Linux kernel. I just don't think that's really a great argument; the last several web projects I've done have been MVC, but I haven't really developed an affection for that format, and some implementations (CakePHP ಠ_ಠ ) make it serious pain in the rear.

I guess "no logical sense" is the most legitimate complaint here, but aren't a lot of programs also like that? A lot of things start out one way and end up finding a niche in something different, and that can make the initial assumptions costly and/or annoying, but I don't think it necessarily taints the whole codebase, though.

Maybe I'm old-fashioned but a huge rap sheet of functions is a lot more workable for me than a lot of OO programs that I've had to deal with.




MVC (or OO) is not a guarantee against bad code, but it does provide some necessary structure, especially for large, extensible projects. Other patterns can also be utilized, but some kind of pattern needs to be implemented. Wordpress had no logical pattern to it's implementation.

Also, MVC wouldn't make sense for the Linux kernel, but it would make a lot of sense for a major CMS.


A lot of the Linux kernel these days is basically OO, at least the parts I look at. It's not in an OO language, but the concepts and patterns are there: an opaque void * "object" that's only accessed via a set of associated "methods", which all have manually name-mangled names like foo_method1 and foo_method2. These "objects" are created via a "constructor" foo_create and destroyed via a manually called "destructor" foo_free, etc. There's even a little bit of manually implemented inheritance and virtual-function stuff going on with function-pointers-in-a-struct type patterns.




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

Search: