rust/compiler/rustc_passes/src
Nicholas Nethercote 75b164d836 Use tidy to sort crate attributes for all compiler crates.
We already do this for a number of crates, e.g. `rustc_middle`,
`rustc_span`, `rustc_metadata`, `rustc_span`, `rustc_errors`.

For the ones we don't, in many cases the attributes are a mess.
- There is no consistency about order of attribute kinds (e.g.
  `allow`/`deny`/`feature`).
- Within attribute kind groups (e.g. the `feature` attributes),
  sometimes the order is alphabetical, and sometimes there is no
  particular order.
- Sometimes the attributes of a particular kind aren't even grouped
  all together, e.g. there might be a `feature`, then an `allow`, then
  another `feature`.

This commit extends the existing sorting to all compiler crates,
increasing consistency. If any new attribute line is added there is now
only one place it can go -- no need for arbitrary decisions.

Exceptions:
- `rustc_log`, `rustc_next_trait_solver` and `rustc_type_ir_macros`,
  because they have no crate attributes.
- `rustc_codegen_gcc`, because it's quasi-external to rustc (e.g. it's
  ignored in `rustfmt.toml`).
2024-06-12 15:49:10 +10:00
..
liveness Match unmatched backticks in compiler/ that are part of rustdoc 2023-03-03 08:39:00 +01:00
abi_test.rs Remove extern crate rustc_middle from numerous crates. 2024-04-29 14:50:45 +10:00
check_attr.rs Fix formatting 2024-06-06 20:27:25 -05:00
check_const.rs Revert "Create const block DefIds in typeck instead of ast lowering" 2024-06-07 08:33:58 +00:00
dead.rs Rollup merge of #125572 - mu001999-contrib:dead/enhance, r=pnkfelix 2024-06-07 20:14:28 +02:00
debugger_visualizer.rs Avoid using feed_unit_query from within queries 2024-03-05 10:02:39 +00:00
diagnostic_items.rs Revert "Rollup merge of #124976 - petrochenkov:usedcrates, r=oli-obk" 2024-06-06 10:06:28 +00:00
entry.rs Various improvements to entrypoint code 2024-05-04 14:48:42 +02:00
errors.rs Error on unsafe on non-unsafe attribute 2024-06-06 20:26:28 -05:00
hir_id_validator.rs Actually create ranged int types in the type system. 2024-04-08 12:02:19 +00:00
hir_stats.rs Rollup merge of #125635 - fmease:mv-type-binding-assoc-item-constraint, r=compiler-errors 2024-05-31 08:50:22 +02:00
lang_items.rs Minor pub and whitespace cleanups. 2024-05-21 14:56:57 +10:00
layout_test.rs Opt-in diagnostics reporting to avoid doing extra work in the new solver 2024-06-03 09:27:52 -04:00
lib.rs Use tidy to sort crate attributes for all compiler crates. 2024-06-12 15:49:10 +10:00
lib_features.rs Remove Session methods that duplicate DiagCtxt methods. 2023-12-24 08:05:28 +11:00
liveness.rs Revert "Create const block DefIds in typeck instead of ast lowering" 2024-06-07 08:33:58 +00:00
loops.rs Revert "Create const block DefIds in typeck instead of ast lowering" 2024-06-07 08:33:58 +00:00
naked_functions.rs Rename BindingAnnotation to BindingMode 2024-04-17 09:34:39 -04:00
reachable.rs reachable computation: clarify comments around consts 2024-06-11 09:08:28 +02:00
stability.rs Revert "Rollup merge of #124976 - petrochenkov:usedcrates, r=oli-obk" 2024-06-06 10:06:28 +00:00
upvars.rs Make body_owned_by return the body directly. 2024-05-29 10:04:08 +00:00
weak_lang_items.rs Revert "Rollup merge of #124976 - petrochenkov:usedcrates, r=oli-obk" 2024-06-06 10:06:28 +00:00