Skip to content
This repository has been archived by the owner on Jan 5, 2021. It is now read-only.

Wrong behavior when existing statename is used as guard on a transition #1043

Closed
BeckmaR opened this issue Oct 18, 2016 · 2 comments
Closed
Assignees
Milestone

Comments

@BeckmaR
Copy link
Contributor

BeckmaR commented Oct 18, 2016

When the user has
interface sensor:
in event measure

and a state named measure and then proceeds to use measure as transition guard (instead of sensor.measure), SCT goes in a loop in TypeInferrer until it finally throws a StackOverflowError in the console. After some time, the validation is done and SCT is usable again, but not showing an Error Marker.
The problem view only shows Error executing EValidator.

Steps to reproduce:

  • Create new Statechart Model
  • Create transition from StateA back to StateA
  • In the transition guard, write StateA.

Also, SCT has no problem with the user declaring

internal:
    event StateA
@tkutz tkutz self-assigned this Oct 18, 2016
@tkutz tkutz added this to the S33 milestone Oct 18, 2016
@tkutz
Copy link
Contributor

tkutz commented Oct 18, 2016

We have a recursion after adding the shortcut method InferenceResult infer(EObject), in order to avoid calling InferenceResult infer(EObject, IValidationIssueAcceptor) with an null acceptor from outside. However "infer" just calls "inferTypeDispatch", which fallbacks to "infer" when no other implementation is found => Recursion

@tkutz
Copy link
Contributor

tkutz commented Oct 20, 2016

Fixed with pull request #1044

@tkutz tkutz closed this as completed Oct 20, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants