Restrict BA property references to unitless or time values 馃 - #3243
Merged
Merged
Conversation
Exercise unitless and time-valued Behavior Annex property references, including preservation of literal units and symbolic prefixed references. Cover disallowed integer, real, constant, record-field, and nonstandard unit types with valid external AADL models. The negative regression currently fails because all nine disallowed references produce no diagnostics. Include corpus baselines and property-set loading for the new model project.
Check declared property, constant, and selected record-field types in BehaviorAnnexValidator and report non-time units at the source reference. Preserve default literal units and symbolic prefixed references for later instance-value selection, and update the conformance record and diagnostic baseline for issue #3191. The regression now reports all nine disallowed references. After rebasing onto master with the build-version fixes, the clean root reactor passes all 143 projects and 1,650 tests with no failures, errors, or skips.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Behavior Annex property references accepted non-time units because validation checked the value representation without enforcing the D.7 unit-category restriction. Check the declared type of referenced properties, constants, and selected record fields, accepting unitless values and
AADL_Project::Time_Unitsand reporting other units at the source reference.Fixes #3191.
The external
issue3191models exercise integer and real properties, constants, record fields,selfand port prefixes, properties without defaults, and a custom units type whose literal is namedms. Before the fix, the negative regression expected nine diagnostics and received none. All three regression tests now pass, including preservation of written time units and symbolic owner/property references. The regression commit precedes the production fix.Validation on the branch rebased onto current
master:All 143 reactor projects passed. Surefire reports contain 1,650 tests across 15 bundles, with zero failures, errors, or skips, including 190 BA tests and all three
Issue3191Testcases.git diff --checkpasses.There are no dependencies on unmerged PRs. The change adds a diagnostic for previously accepted non-time units. Effective instance-value selection remains part of #3229; translation continues to preserve prefixed references symbolically.