Auto merge of #145284 - nnethercote:type_name-print-regions, r=lcnr

Print regions in `type_name`.

Currently they are skipped, which is a bit weird, and it sometimes causes malformed output like `Foo<>` and `dyn Bar<, A = u32>`.

Most regions are erased by the time `type_name` does its work. So all regions are now printed as `'_` in non-optional places. Not perfect, but better than the status quo.

`c_name` is updated to trim lifetimes from MIR pass names, so that the `PASS_NAMES` sanity check still works. It is also renamed as `simplify_pass_type_name` and made non-const, because it doesn't need to be const and the non-const implementation is much shorter.

The commit also renames `should_print_region` as `should_print_optional_region`, which makes it clearer that it only applies to some regions.

Fixes rust-lang/rust#145168.

r? `@lcnr`
tree: b3682a185c41624677ba02026f6677cf2a1bbcf0
  1. .github/
  2. ci/
  3. crates/
  4. examples/
  5. intrinsics_data/
  6. .cirrus.yml
  7. .git-blame-ignore-revs
  8. .gitignore
  9. .gitmodules
  10. Cargo.lock
  11. Cargo.toml
  12. CONTRIBUTING.md
  13. josh-sync.toml
  14. LICENSE-APACHE
  15. LICENSE-MIT
  16. README.md
  17. rust-version
  18. rustfmt.toml
  19. triagebot.toml
  20. vendor.yml
README.md

stdarch - Rust's standard library SIMD components

Actions Status

This repository contains the core_arch crate, which implements core::arch - Rust's core library architecture-specific intrinsics.

The std::simd component now lives in the packed_simd_2 crate.

Synchronizing josh subtree with rustc

This repository is linked to rust-lang/rust as a josh subtree. You can use the rustc-josh-sync tool to perform synchronization.

You can find a guide on how to perform the synchronization here.