Skip to content

Provide compile errors from #[ast] macro #124

@overlookmotel

Description

@overlookmotel

#[ast] attribute is not meaningful unless the type it's on is in a file which is processed by AST codegen.

Make macro raise an error/panic if the file path needs to be added to AST codegen, with an error that says what to do. This will help people do the right thing.

  • Error on invalid arguments to generate_derive (#4766)
  • Error if fundamental type names such as Span and primitives don't meet our expectations
  • Error on usage of #[ast] attribute on types outside of ast_codegen's view

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions