about summary refs log tree commit diff
path: root/compiler/rustc_thread_pool
diff options
context:
space:
mode:
authorJacob Pratt <jacob@jhpratt.dev>2025-09-13 03:26:01 -0400
committerGitHub <noreply@github.com>2025-09-13 03:26:01 -0400
commit544644476d9c304648801dae76d85b1c17fc35d1 (patch)
treeceeb6ffcfbe92d361b50563382d416df6a2663d3 /compiler/rustc_thread_pool
parent9642c0ef6749e57ce76ac153807df1cc38cd26ee (diff)
parentf157ce994ea45e9faea9eff89c5f8b3d4ea77b6e (diff)
downloadrust-544644476d9c304648801dae76d85b1c17fc35d1.tar.gz
rust-544644476d9c304648801dae76d85b1c17fc35d1.zip
Rollup merge of #144498 - Noratrieb:rustc-json-schema, r=jieyouxu,davidtwco
Add --print target-spec-json-schema

This schema is helpful for people writing custom target spec JSON. It can provide autocomplete in the editor, and also serves as documentation when there are documentation comments on the structs, as `schemars` will put them in the schema.

I was motivated to do this because I saw someone write their own version of this schema by hand, so demand for this clearly exists. It's not a lot of effort to implement, so I thought it would make sense.

MCP: https://github.com/rust-lang/compiler-team/issues/905

I think it would also be useful to put this in the sysroot in `etc` so people can link it directly in their editors.

I would have loved to add a test that validates the JSON schema against the spec JSON of every builtin target, but I don't want to do it as the JSON schema validation crates have incredible amounts of dependencies because JSON schema supports a ton of random features. I don't want to add that, even as a dev dependency.
Diffstat (limited to 'compiler/rustc_thread_pool')
0 files changed, 0 insertions, 0 deletions