Commit Graph

6 Commits

Author SHA1 Message Date
Alona Enraght-Moony
078332fdc8 rustdoc-json: Structured attributes
Implements https://www.github.com/rust-lang/rust/issues/141358.

This has 2 primary benefits:

1. For rustdoc-json consumers, they no longer need to parse strings of
   attributes, but it's there in a structured and normalized way.
2. For rustc contributors, the output of HIR pretty printing is no
   longer a versioned thing in the output. People can work on
   https://github.com/rust-lang/rust/issues/131229 without needing to
   bump `FORMAT_VERSION`.

(Over time, as the attribute refractor continues, I expect we'll add new
things to `rustdoc_json_types::Attribute`. But this can be done
separately to the rustc changes).
2025-07-15 16:52:41 +00:00
bors
7e310f4b9a Auto merge of #143617 - aDotInTheVoid:devdesktoptestattr, r=Mark-Simulacrum
Run `tests/rustdoc-json/attrs/target_features` on all hosts.

Makes it more convenient to test rustdoc on non x86_64. I mainly care about the aarch64 dev-desktops.

This works because rustdoc uses all target features, not just that of the target.
2025-07-13 12:28:47 +00:00
Fluid
ed96f00682 fix typos in function names in the target_feature test 2025-07-11 02:27:39 +03:00
Predrag Gruevski
717041232a Don't mark #[target_feature] safe fns as unsafe in rustdoc JSON. 2025-07-08 02:02:56 +00:00
Alona Enraght-Moony
45053e21b2 Run tests/rustdoc-json/attrs/target_features on all hosts.
Makes it more convenient to test rustdoc on non x86_64. I mainly care
about the aarch64 dev-desktops.

This works because rustdoc uses all target features, not just that of
the target.
2025-07-07 21:56:54 +00:00
Jonathan Brouwer
3d5d72b761 Port #[target_feature] to the new attribute parsing infrastructure
Signed-off-by: Jonathan Brouwer <jonathantbrouwer@gmail.com>
2025-07-03 07:54:19 +02:00