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

Represent type information in the Trustfall schema #149

Open
obi1kenobi opened this issue Oct 15, 2022 · 0 comments
Open

Represent type information in the Trustfall schema #149

obi1kenobi opened this issue Oct 15, 2022 · 0 comments
Labels
A-lint Area: new or existing lint C-enhancement Category: raise the bar on expectations

Comments

@obi1kenobi
Copy link
Owner

Currently, the schema that lints query does not represent type information. This means that lints like "changed the type of a pub field" can't be written since we can't compare the before-and-after types of fields, function parameters, etc.

The current schema cargo-semver-checks is defined here: https://github.com/obi1kenobi/trustfall-rustdoc-adapter/blob/main/src/rustdoc_schema.graphql

Any schema design needs to consider (and provide examples for):

  • How we'd represent generic types (Vec<usize>), lifetime information (&'a u64), tuples, dyn Trait, etc.
  • What queries that compare types would look like.
  • How to ensure there are no false-positives in semver lints, while also keeping the schema as simple as possible.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-lint Area: new or existing lint C-enhancement Category: raise the bar on expectations
Projects
None yet
Development

No branches or pull requests

1 participant