News for hackers. Stuff that matters.
Re:The pyramid of code quality (Part II), the 3 different ty... by swombat on Sunday May 10, 2009 @01:24PM (#602276)
I'm sorry, but this sounds like a very contrived analogy that oversimplifies reality for the purpose of explaining what is really a simple concept.

In addition, this analogy is wrong. Over-engineered code is as much in need of a refactoring as under-engineered code.

Re:The pyramid of code quality (Part II), the 3 different ty... by warfangle on Monday May 11, 2009 @09:17AM (#603415)
Over-engineering tends to happen when people plan out the entire structure of an application or codebase before starting.

Under-engineering happens when deadlines pile up and there is no time to refactor to known and useful design patterns. Or, in the worst-case scenario, the developer has no idea about design patterns. Most code out there is bad due to the latter two reasons, not the former one.

Over-engineered code, yes, is often denser than it needs to be. But oftentimes it's a lot easier to come in and understand it than, say, a 16000 line PHP file with no functions or objects - just a bunch of nested if/else... I'd argue that the former is possible to refactor, while you're better off just dousing the Gordian Knot code in kerosene and tossing a match on it.

Re:The pyramid of code quality (Part II), the 3 different ty... by swombat on Monday May 11, 2009 @11:03AM (#603576)
Hah, so what you're saying is the "code that needs to be refactored" is actually "code that needs to be thrown away"... :-)
Re:The pyramid of code quality (Part II), the 3 different ty... by warfangle on Monday May 11, 2009 @11:48AM (#603666)
Sometimes, but not always! Often over-engineered code can simply be reorganized to something simpler and more intuitive (and oftentimes, more efficient). The same is usually not true of spaghetti code...
Re:The pyramid of code quality (Part II), the 3 different ty... by albertoG on Sunday May 10, 2009 @03:45PM (#602398)
Hi swombat, thanks for your comment, I actually completely agree on what you say: "Over-engineered code is as much in need of a refactoring as under-engineered code" I should have also mention that on the original article. Good observation, thanks!!!!
Re:The pyramid of code quality (Part II), the 3 different ty... by gengstrand on Sunday May 10, 2009 @04:02PM (#602405)
I think that the point is that the ratio of framework to functionality code is a relevant indicator when evaluating overall code quality in an application or system.
Re:The pyramid of code quality (Part II), the 3 different ty... by callmeed on Sunday May 10, 2009 @12:47PM (#602246)
Interesting topic, but hard to read ... is there a pyramid of good writing/grammar?
Re:The pyramid of code quality (Part II), the 3 different ty... by albertoG on Sunday May 10, 2009 @03:41PM (#602395)
Hi callmeed and any other eventual reader, please accept my apologies for my bad writing in English, I hope you will understand it's not my native language and that I do my best, anyway, going forward I will try to get my articles reviewed from some native speaker guy before publishing them. Thanks for your comment!!!