rust/compiler/rustc_codegen_ssa
许杰友 Jieyou Xu (Joe) b477f89041
Rollup merge of #125750 - compiler-errors:expect, r=lcnr
Align `Term` methods with `GenericArg` methods, add `Term::expect_*`

* `Term::ty` -> `Term::as_type`.
* `Term::ct` -> `Term::as_const`.
* Adds `Term::expect_type` and `Term::expect_const`, and uses them in favor of `.ty().unwrap()`, etc.

I could also shorten these to `as_ty` and then do `GenericArg::as_ty` as well, but I do think the `as_` is important to signal that this is a conversion method, and not a getter, like `Const::ty` is.

r? types
2024-06-04 08:25:48 +01:00
..
src Rollup merge of #125750 - compiler-errors:expect, r=lcnr 2024-06-04 08:25:48 +01:00
Cargo.toml Make SSA aggregates without needing an alloca 2024-05-08 20:38:04 -07:00
messages.ftl emit an error if we can't find a path to the self-contained linker 2024-05-23 15:47:35 +00:00
README.md mv compiler to compiler/ 2020-08-30 18:45:07 +03:00

Please read the rustc-dev-guide chapter on Backend Agnostic Codegen.