Skip to content

Commit

Permalink
Auto merge of #133409 - RalfJung:target-consistency, r=lcnr
Browse files Browse the repository at this point in the history
ensure JSON-defined targets are consistent

We have a `check_consistency` check that ensures some invariants which (presumably) the rest of the compiler relies on. However, JSON targets can easily be written in a way that violates those invariants. So this PR applies the same consistency check to JSON targets that we already enforce for built-in targets.

I have converted many of the assertions in that function to new macros that show a nice error instead of a panic; if people are okay with the general approach here, I can do that for the rest of the checks as well.
  • Loading branch information
bors committed Nov 28, 2024
2 parents 9b4d7c6 + 77080d8 commit 188f378
Show file tree
Hide file tree
Showing 5 changed files with 1,139 additions and 975 deletions.
Loading

0 comments on commit 188f378

Please sign in to comment.