#ast #rustc-auto-publish #pretty-print #syntax-tree #macro-expansion

nightly rustc-ap-syntax

Automatically published version of the package syntax in the rust-lang/rust repository from commit 834bc5650acf7019a53b409db68986857822812c The publishing script for this crate lives at: https://github.com/alexcrichton/rustc-auto-publish

611 major breaking releases

645.0.0 Feb 25, 2020
644.0.0 Feb 18, 2020
643.0.0 Feb 11, 2020
642.0.0 Feb 8, 2020
1.0.0 Jan 11, 2018

#2522 in Procedural macros

Download history 1052/week @ 2025-10-28 308/week @ 2025-11-04 306/week @ 2025-11-11 691/week @ 2025-11-18 477/week @ 2025-11-25 498/week @ 2025-12-02 84/week @ 2025-12-09 170/week @ 2025-12-23 12/week @ 2025-12-30 99/week @ 2026-01-06 108/week @ 2026-01-13 30/week @ 2026-01-20 58/week @ 2026-01-27 41/week @ 2026-02-03 248/week @ 2026-02-10

387 downloads per month
Used in 5 crates (4 directly)

MIT/Apache

1.5MB
30K SLoC

The Rust parser and macro expander.

Note

This API is completely unstable and subject to change.


The syntax crate contains those things concerned purely with syntax – that is, the AST ("abstract syntax tree"), parser, pretty-printer, lexer, macro expander, and utilities for traversing ASTs.

For more information about how these things work in rustc, see the rustc guide:

Dependencies

~7.5MB
~139K SLoC