Changes between Version 33 and Version 34 of Guidelines/MaintenanceGuidelines


Ignore:
Timestamp:
Nov 20, 2009, 4:52:11 PM (13 years ago)
Author:
Paul A. Bristow
Comment:

Added statement of philosophy from Robert Stewart

Legend:

Unmodified
Added
Removed
Modified
  • Guidelines/MaintenanceGuidelines

    v33 v34  
    547547avoiding vendor specific extensions if possible.
    548548
    549 See also [https://svn.boost.org/trac/boost/wiki/WarningFixes] for progress on warning suppression.[[BR]]
     549Warnings often indicate real problems.  Sometimes they only manifest
     550on a particular platform, revealing a portability issue.  Sometimes
     551they indicate that the code doesn't account for a runtime condition,
     552like overflow, which the warning can only suggest as a possibility.
     553
     554Suppressing a warning without altering code may simply mask a problem.
     555The right approach is to determine why the warning occurs is to decide
     556whether it is correct in the context, and if so, apply appropriate remediation.
     557If the warning is not correct in the context, only then should it be suppressed.
     558
     559Because developers don't have the same knowledge, even among Boost
     560developers, Boost is amassing information to help them know when a
     561warning is significant and not.  That information can show cases in
     562which a warning is legitimate and when it isn't.  For the former,
     563there is help to understand how to change the code portably to
     564account for the problem revealed by the warning.  For the latter,
     565there is information on how to suppress the warning in a portable way.
     566
     567Changing code can lead to bugs.  Thus, changing code to eliminate a warning might create a bug.  That's unfortunate.
     568From a maintenance standpoint, however, most would prefer to see altered code to a
     569glob of preprocessor and pragma line noise that suppresses a warning in the unchanged code.
     570
     571Testing will reveal the bug.  If it doesn't, the testing is insufficient.
     572If the bug appears on an untested platform, then more testers are needed to be able to detect such bugs in the future.
     573
     574See also [https://svn.boost.org/trac/boost/wiki/WarningFixes] for progress made on warning fixes/suppression.[[BR]]
    550575
    551576'''Reasons to eliminate or suppress warnings:'''