Skip to content

Struct wide configuration #3

@Nukesor

Description

@Nukesor

The idea is to add some configuration options to the struct attributes.

This might look like this:

#[derive(InterStruct)]
#[merge("crate::Target", strict)]
pub struct Source {
    pub normal: String,
    pub optional: Option<String>,
}

For now these are the planned configuration flags:

  • strict Enforces that all fields (unless ignored) are mapped to the target struct.
    A compiler error will be thrown if any fields cannot be found on the target struct.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions