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

Render certain EDS constructs as a union #41

Closed
jphickey opened this issue Mar 13, 2023 · 0 comments · Fixed by #45
Closed

Render certain EDS constructs as a union #41

jphickey opened this issue Mar 13, 2023 · 0 comments · Fixed by #45
Assignees

Comments

@jphickey
Copy link
Contributor

Is your feature request related to a problem? Please describe.
The LC app (https://github.com/nasa/LC) uses a union for its LC_MultiType_t container. This is used in the table definitions so it can have any data type. Unfortunately, the EDS cannot currently generate a structure that can represent this.

Describe the solution you'd like
Render a specific EDS construct as a union so it will be compatible with this use-case in LC.

Additional context
This is just a specialized/specific case of container inheritance. The EDS tool does render a union for container types that are used as a base type for other objects, but it renders it abstractly - that is, there is just a max size and alignment, the members and member types are not explicitly listed, as this might create a circular dependency if they are in another datasheet.

In this case, all the derived types are in the same datasheet, so there is no dependency issue. In this context the tool can render a union with all the members and it should address the LC use case.

Requester Info
Joseph Hickey, Vantage Systems, Inc.

@jphickey jphickey self-assigned this Mar 13, 2023
jphickey added a commit to jphickey/EdsLib that referenced this issue Mar 13, 2023
If a datasheet/packagefile defines all derived containers then render
that object in C as a normal union with all members, as opposed to the
abstract union that would be rendered if types came from different
package files.
dzbaker added a commit that referenced this issue Mar 16, 2023
Fix #41, render union members if all in same EDS
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant