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

Footer after field with size defined by message size #490

Closed
treiher opened this issue Nov 4, 2020 · 1 comment · Fixed by #889
Closed

Footer after field with size defined by message size #490

treiher opened this issue Nov 4, 2020 · 1 comment · Fixed by #889
Assignees
Labels
bug model Related to model package (e.g., model verification)

Comments

@treiher
Copy link
Collaborator

treiher commented Nov 4, 2020

It should be possible to have a footer after a field, which size is defined by the message size.

package Test is

   type T is mod 2**8;

   type M is
      message
         A : T;
         B : Opaque
            with Size => Message'Size - 2 * Test::T'Size;
         C : T;
      end message;

end Test;
test.rflx:8:10: model: error: negative size for field "B" (A -> B)
@treiher treiher added bug model Related to model package (e.g., model verification) labels Nov 4, 2020
@treiher
Copy link
Collaborator Author

treiher commented Oct 11, 2021

The use case can be realized using parameterized messages. The issue will be obsolete after realization of #736 , as the use of Message'Size in size aspects will be prohibited. At the moment, it is not planned to support the use case using Message'Size.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug model Related to model package (e.g., model verification)
Projects
None yet
1 participant