-
Notifications
You must be signed in to change notification settings - Fork 50
Fix issues in OCL checks #1850 #2002
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: 3.0.x
Are you sure you want to change the base?
Conversation
- fix warnings about double quotes - repair subapp-invariants for TypedSubApps and UntypedSubapps Fixes: eclipse-4diac#1850
Test Results 110 files ±0 110 suites ±0 1m 9s ⏱️ -1s Results for commit d98b2c1. ± Comparison against base commit c387184. This pull request removes 29 and adds 11 tests. Note that renamed tests count towards both. |
| -- Problem: Dead states | ||
| context ECState | ||
| inv "WARNING;[DeadState]" : not self.isStartState() implies (self->closure(inTransitions.source)->select(state : ECState | state.isStartState())->size() > 0) | ||
| inv _'WARNING;[DeadState]" : not self.isStartState() implies (self->closure(inTransitions.source)->select(state : ECState | state.isStartState())->size() > 0) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| inv _'WARNING;[DeadState]" : not self.isStartState() implies (self->closure(inTransitions.source)->select(state : ECState | state.isStartState())->size() > 0) | |
| inv _'WARNING;[DeadState]' : not self.isStartState() implies (self->closure(inTransitions.source)->select(state : ECState | state.isStartState())->size() > 0) |
| context TypedSubApp | ||
| inv _'WARNING;[EmptySubApp]': self.getSubAppNetwork() = null or self.getSubAppNetwork().getBlockFBNetworkElements()->size() > 0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does it actually make sense to have these warnings at instances of typed subapps?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As far as I can tell: currently the options are to
- have it detected for the instances or
- not have the warning at all as the OCL checks are performed based on the application
Moving this check to the types would require an additional set of OCL-rules that are applied based on the Type Library. Those rules would then apply to all types in the Type Library and not just the ones that are acutally in use; Maybe the people that developed the code-smell-concept (e.g. @LisaSonnleithner) can help here to clarify?
Fixes: #1850