Skip to content

ogma-core: Simplify struct generation #199

@ivanperez-keera

Description

@ivanperez-keera

Description

Copilot 4.2 introduced a simpler way of defining the class instances needed to work with structs in Copilot. Thanks to generics, it is now possible to use default versions of most functions (but they have to be explicitly stated).

We should update Ogma to generate simpler code, which will also simplify Ogma's code.

Type

  • Management: Update to leverage capabilities of new versions of Copilot.

Additional context

  • Issue #564 introduced a simpler method to work with structs in Copilot.

Requester

  • Ivan Perez.

Method to check presence of bug

Not applicable (not a bug).

Expected result

Ogma generates simpler code that defaults to typeNameDefault and other similar functions when generating type class instances for Copilot structs.

Desired result

Ogma generates simpler code that defaults to typeNameDefault and other similar functions when generating type class instances for Copilot structs.

Proposed solution

Modify Ogma's Copilot struct backend to make structs an instance of Generic, and to leverage the new default functions where possible.

Further notes

None.

Metadata

Metadata

Labels

CR:Status:ClosedAdmin only: Change request that has been completedCR:Type:ManagementAdmin only: Change request for conformance with policies or procedures

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions