Skip to content

Disallow import of structs with access(contract) initializersΒ #4304

@bluesign

Description

@bluesign

Issue to be solved

I was checking DefiActions and stumble upon to

https://github.com/onflow/FlowActions/blob/5e217417f5898eca2fab8837e541b95816f80f2f/cadence/contracts/interfaces/DeFiActions.cdc#L125C3-L129C1

I think this is pretty ugly and we should not need tricks like this when coding with Cadence

Suggested Solution

I think disallowing import of structs with access(contract) initializers is the best way to solve.this.

PS: I am on some kind of sabbatical but happy to create a FLIP for it if necessary

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions