Mandatory DECIMAL and MONEY precision rules

The mandatory decimal precision rule checks to see that a precision has been defined for an identifier of the DECIMAL or MONEY data type.

The ruleId

The ruleId is type.precision.mandatory, where type is:
  • decimal
  • money


The options available for mandatory DECIMAL and MONEY precision rules are:
  • .enabled specifies whether a rule is enabled. Valid values are true or false.
  • .severity specifies the severity level. Valid values are error, info, or warning (default).
    Warning: If the severity is set to error, the compilation will fail if the rule is broken.


To check that all DECIMAL identifiers specify a precision, and to output a warning if an exception is found, specify these rules:
decimal.precision.mandatory.enabled = true
decimal.precision.mandatory.severity = warning

Additional examples are provided in the default.gslint file.