Code Smell Template

I just copied this from the AntiPatternTemplate. If something should be added or reworded, go ahead and do it. In particular, some of the slot descriptions could use amplification.

Every slot should contain accurate information and descriptions, except those explicitly marked "supposed". This should cut down on some of the confusion people have with AntiPatterns and which parts are good or bad.

Discussion about this template should probably go on CodeSmellTemplateDiscussion?, just so it's easier for users to cut and paste the template itself.

When the template has evolved to a stable state, it might make sense to go back and restructure existing CodeSmell using it.


CodeSmell Name: [name]

Type: [Design | Organizational | ...]

Problem: [what you really want to solve; present a simple concrete example]

Context: [context]

Forces: [forces]

Supposed Solution: [the bad solution; explain in terms of your concrete example]

Resulting Context: [what happens when you apply it, good and bad]

Design Rationale: [rationale]

Related AntiPatterns:

Applicable Positive Patterns:

AntiPatternCategory: [classify it]

Also Known As: [other names]


Examples in the Literature:


Examples in Practice:


CategoryPatternForm CategoryCodeSmell


EditText of this page (last edited June 30, 2010) or FindPage with title or text search