Skip to content
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

Importing a reactor with instance in a mode triggers a NPE #2269

Closed
edwardalee opened this issue Apr 26, 2024 · 1 comment · Fixed by #2270
Closed

Importing a reactor with instance in a mode triggers a NPE #2269

edwardalee opened this issue Apr 26, 2024 · 1 comment · Fixed by #2270
Assignees
Labels
bug Something isn't working
Milestone

Comments

@edwardalee
Copy link
Collaborator

File lib/InstanceInMode.lf instantiates a reactor inside a mode:

target C
reactor U {
  reaction(startup) {==}
}
reactor B {
  reaction(startup) {==}
  initial mode A {
    u = new U()   
  }
}

File ImportInstanceInMode.lf imports the outer reactor:

target C {
  timeout: 0s
}
import B from "lib/InstanceInMode.lf"
main reactor {
  b = new B()
}

Compiling this program triggers a null-pointer exception.

@edwardalee edwardalee added the bug Something isn't working label Apr 26, 2024
@edwardalee edwardalee self-assigned this Apr 26, 2024
@lhstrh lhstrh added this to the 0.8.0 milestone Apr 27, 2024
@edwardalee
Copy link
Collaborator Author

This is fixed in PR #2270.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants