Skip to content

Auto generate property initialisers #5

Open
@helje5

Description

@helje5

If the dev didn't specify an own initialiser, the macro should generate one, similar to what Swift itself already does for structures.

E.g.:

@Model class Item: NSManagedObject {
  var date : Date
}

Should generate:

convenience init(date: Date) {
  self.init()
  self.date = date
}

The code for this is already prepared in the Model macro, needs to be finished.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requesthelp wantedExtra attention is needed

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions