oxc-project / oxc-project/backlog
Provide compile errors from `#[ast]` macro
Nobody has claimed this yet.
- Dominant language
- No language data
- Stars
- 7
- Forks
- 0
- PR merge metrics
- No merged PRs in 30d
Description
#[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
Spanand primitives don't meet our expectations - Error on usage of
#[ast]attribute on types outside ofast_codegen's view
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Trace #[ast] handling through ast_codegen and generate_derive, starting with how invalid arguments currently produce errors. Confirm the expected behavior for types outside ast_codegen's view and the guidance the diagnostic should provide. Done means misuse produces a clear compile error explaining how to add the file to AST codegen.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- compilers
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100