Dernièrement discutant de conception et de programmation avec un programmeur externe, il m’expliqua son approche de programmation défensive.
Mais avant d’aller dans le détail de ses explications, Wikipédia aide-nous à définir la programmation défensive :
Defensive programming is a form of defensive design intended to ensure the continuing function of a piece of software under unforeseen circumstances. The idea can be viewed as reducing or eliminating the prospect of Finagle’s law having effect. Defensive programming techniques are used especially when a piece of software could be misused.