Converting sdisc/udisc to limitInt/wrapInt

Elements that use the deprecated sdisc/udisc types can be converted to limitInt/wrapInt types.

Several conversion rules apply to these conversions, context of a project as well as several restrictions. For each element that cannot be converted, an information message is shown in the ASCET monitor window.

See Converting Old Integer Types to New Integer Types for a step-by-step instruction.

If desired, you can test the new behavior for integer types before you convert them permanently.

Conversion Rules

Unless otherwise noted, the rules listed here apply to database/workspace-wide conversion and component-wide conversion.

  1. IF

    all existing implementations of an exported or local sdisc/udisc element are identical

    AND

    the formula is the identity formula

    AND

    the Limit Assignments option is activated,

    THEN

    the element is converted to limitInt. The implementation interval is used as min/max for the new type.

  2. IF

    all existing implementations of an exported or local sdisc/udisc element are identical

    AND

    the formula is the identity formula

    AND

    the Limit Assignments option is deactivated,

    THEN

    the element is converted to wrapInt. The implementation data type is used as type for wrapInt, the implementation interval is used as min/max for the new type.

  3. Imported elements have no implementation.

    1. In the context of a project, an imported element is converted in the same way as its exported counterpart.
    2. Without project context, imported elements are not converted.
  4. Elements in child components of a project are converted if rules 1 – 3 are fulfilled.
  5. In all other cases, the element is not converted.

Restrictions

The following restrictions apply to database/workspace-wide and component-wide conversions of sdisc/udisc to limitInt/wrapInt:

The following restrictions apply only to database/workspace-wide conversions of sdisc/udisc to limitInt/wrapInt:

The following restrictions apply only to component-wide conversions of sdisc/udisc to limitInt/wrapInt:

See also

Converting Old Integer Types to New Integer Types

Scalar Types

Scalar Types: Limited Integer

Scalar Types: Wrap-Around Integer

Using the Conversion Operator

Conversion Operations

Testing the New Behavior for Integer Types