rust/compiler/rustc_ast/src
bors 08db600e8e Auto merge of #135186 - camelid:const-path-multi, r=BoxyUwU
mgca: Lower all const paths as `ConstArgKind::Path`

When `#![feature(min_generic_const_args)]` is enabled, we now lower all
const paths in generic arg position to `hir::ConstArgKind::Path`. We
then lower assoc const paths to `ty::ConstKind::Unevaluated` since we
can no longer use the anon const expression lowering machinery. In the
process of implementing this, I factored out `hir_ty_lowering` code that
is now shared between lowering assoc types and assoc consts.

This PR also introduces a `#[type_const]` attribute for trait assoc
consts that are allowed as const args. However, we still need to
implement code to check that assoc const definitions satisfy
`#[type_const]` if present (basically is it a const path or a
monomorphic anon const).

r? `@BoxyUwU`
2025-03-04 22:37:37 +00:00
..
attr Remove NtPath. 2025-02-28 08:42:14 +11:00
expand clean up autodiff code/comments 2025-02-21 21:47:48 -05:00
util Replace ast::TokenKind::BinOp{,Eq} and remove BinOpToken. 2025-03-03 09:26:11 +11:00
ast_traits.rs Implment #[cfg] and #[cfg_attr] in where clauses 2025-03-01 22:02:46 +08:00
ast.rs mgca: Lower all const paths as ConstArgKind::Path 2025-03-04 10:11:13 -05:00
entry.rs remove support for the #[start] attribute 2025-01-21 06:59:15 -07:00
format.rs Account for format_args in HiddenUnicodeCodepoints lint 2024-12-31 05:03:22 +00:00
lib.rs Add hir::Attribute 2024-12-15 19:18:46 +01:00
mut_visit.rs Implment #[cfg] and #[cfg_attr] in where clauses 2025-03-01 22:02:46 +08:00
node_id.rs Reformat use declarations. 2024-07-29 08:26:52 +10:00
ptr.rs Convert some Into impls into From impls 2024-12-31 01:56:33 +00:00
token.rs Rename ast::TokenKind::Not as ast::TokenKind::Bang. 2025-03-03 09:26:13 +11:00
tokenstream.rs Rename ast::TokenKind::Not as ast::TokenKind::Bang. 2025-03-03 09:26:13 +11:00
visit.rs Implment #[cfg] and #[cfg_attr] in where clauses 2025-03-01 22:02:46 +08:00