Normalize the handling of assertion policies
The Ada compiler now normalizes assertion policies to `Check` and `Ignore` to prevent internal logic errors.
The Ada compiler’s handling of assertion policies has been normalized to use Check and Ignore consistently. Previously, On and Off were also used, leading to potential internal logic errors. By normalizing the policy names in the Policy_In_Effect function within sem_util.adb, the compiler’s behavior becomes more predictable and robust.
In Details
The commit normalizes policy names in Policy_In_Effect within sem_util.adb. The policy names are now consistently Check and Ignore. Search context: Ada compiler assertion policies Policy_In_Effect Check Ignore
For Context
Assertions are checks inserted into the code to verify that certain conditions are true. Ada allows you to specify policies for how assertions are handled (e.g., whether they are checked or ignored). This commit ensures that the Ada compiler uses consistent names for these policies internally, which improves the reliability of the compiler. Search context: Ada compiler assertion policies Policy_In_Effect Check Ignore