Skip to content

Require adding entries to the Kind enum to be done at the end of the enum #3615

Open
@abitofevrything

Description

@abitofevrything

Since the types of elements are returned as indices into the Kind enum in the generated index.json file, any additions to the Kind enum are effectively a breaking change for any tooling consuming that file as their indices will no longer line up with dartdoc's.
We observed this as our version of dartdoc had the new Kind.extensionType whereas the version of dartdoc used to generate the file we were consuming did not.

This can be mitigated by only ever adding new types at the end of the Kind enum, so the indices of existing element types remain the same. It'd be nice if this could be required for future additions to the enum.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2A bug or feature request we're likely to work ontype-enhancementA request for a change that isn't a bug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions