Package SCons :: Module Warnings
[hide private]
[frames] | no frames]

Module Warnings

source code

SCons.Warnings

This file implements the warnings framework for SCons.

Classes [hide private]
  Warning
  WarningOnByDefault
  CacheWriteErrorWarning
  CorruptSConsignWarning
  DependencyWarning
  DuplicateEnvironmentWarning
  FutureReservedVariableWarning
  LinkWarning
  MisleadingKeywordsWarning
  MissingSConscriptWarning
  NoMD5ModuleWarning
  NoMetaclassSupportWarning
  NoObjectCountWarning
  NoParallelSupportWarning
  ReservedVariableWarning
  StackSizeWarning
  VisualCMissingWarning
  VisualVersionMismatch
  VisualStudioMissingWarning
  FortranCxxMixWarning
  FutureDeprecatedWarning
  DeprecatedWarning
  MandatoryDeprecatedWarning
  PythonVersionWarning
  DeprecatedSourceCodeWarning
  DeprecatedBuildDirWarning
  TaskmasterNeedsExecuteWarning
  DeprecatedCopyWarning
  DeprecatedOptionsWarning
  DeprecatedSourceSignaturesWarning
  DeprecatedTargetSignaturesWarning
  DeprecatedDebugOptionsWarning
  DeprecatedSigModuleWarning
  DeprecatedBuilderKeywordsWarning
Functions [hide private]
 
suppressWarningClass(clazz)
Suppresses all warnings that are of type clazz or derived from clazz.
source code
 
enableWarningClass(clazz)
Enables all warnings that are of type clazz or derived from clazz.
source code
 
warningAsException(flag=1)
Turn warnings into exceptions.
source code
 
warn(clazz, *args) source code
 
process_warn_strings(arguments)
Process string specifications of enabling/disabling warnings, as passed to the --warn option or the SetOption('warn') function.
source code
Variables [hide private]
  __revision__ = 'src/engine/SCons/Warnings.py 5134 2010/08/16 2...
  _enabled = [(<class 'SCons.SConf.SConfWarning'>, 1)]
  _warningAsException = 0
  _warningOut = None
hash(x)
  __package__ = 'SCons'
Function Details [hide private]

warningAsException(flag=1)

source code 
Turn warnings into exceptions. Returns the old value of the flag.

process_warn_strings(arguments)

source code 

Process string specifications of enabling/disabling warnings, as passed to the --warn option or the SetOption('warn') function.

An argument to this option should be of the form <warning-class> or no-<warning-class>. The warning class is munged in order to get an actual class name from the classes above, which we need to pass to the {enable,disable}WarningClass() functions. The supplied <warning-class> is split on hyphens, each element is capitalized, then smushed back together. Then the string "Warning" is appended to get the class name.

For example, 'deprecated' will enable the DeprecatedWarning class. 'no-dependency' will disable the DependencyWarning class.

As a special case, --warn=all and --warn=no-all will enable or disable (respectively) the base Warning class of all warnings.


Variables Details [hide private]

__revision__

Value:
'src/engine/SCons/Warnings.py 5134 2010/08/16 23:02:40 bdeegan'