D'un autre cote, le commentaire n'est pas necessairement le reflet de la qualite d'un logiciel. Avec des fonctions bien nommes un chemin algorithmique clair, on arrive a de bien meilleur resultats qu'un commentaire. Si tu as besoin de mettre 5 lignes de commentaire pour expliquer ce que tu fais, c'est un peu louche.
Exemple:
/* we call this function to check for incorrect syntax */
check_string_1( s );
/* we call this function to check for wrong attributes references */
check_string_2( s );
A comparer a
check_string_for_bad_syntax( s );
check_string_for_wrong_attribute( s );
Je prefere nettement la seconde version, bien qu'elle soit moins commentee.
[^] # Re: ha ?!??
Posté par Philippe F (site web personnel) . En réponse à la dépêche Démarche qualité et Logiciel Libre. Évalué à 10.
Exemple:
/* we call this function to check for incorrect syntax */
check_string_1( s );
/* we call this function to check for wrong attributes references */
check_string_2( s );
A comparer a
check_string_for_bad_syntax( s );
check_string_for_wrong_attribute( s );
Je prefere nettement la seconde version, bien qu'elle soit moins commentee.