Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

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

Open
abitofevrything opened this issue Jan 5, 2024 · 0 comments
Labels
P2 A bug or feature request we're likely to work on type-enhancement A request for a change that isn't a bug

Comments

@abitofevrything
Copy link

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.

@srawlins srawlins added P2 A bug or feature request we're likely to work on type-enhancement A request for a change that isn't a bug labels Mar 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
P2 A bug or feature request we're likely to work on type-enhancement A request for a change that isn't a bug
Projects
None yet
Development

No branches or pull requests

2 participants