diff options
| author | Jana Dönszelmann <jana@donsz.nl> | 2025-08-24 13:14:27 +0200 |
|---|---|---|
| committer | Jana Dönszelmann <jana@donsz.nl> | 2025-09-08 14:57:28 -0700 |
| commit | a38288bbe00f64204967819fd2cfe107a7902404 (patch) | |
| tree | 1f706e820cfe614ba69d65d41c8b6922acfce898 /compiler/rustc_hir | |
| parent | 92f24020967e4e1f1375dbb2d1ba85cd4430fc78 (diff) | |
| download | rust-a38288bbe00f64204967819fd2cfe107a7902404.tar.gz rust-a38288bbe00f64204967819fd2cfe107a7902404.zip | |
port `#[move_size_limit]` to the new attribute parsing infrastructure
Diffstat (limited to 'compiler/rustc_hir')
| -rw-r--r-- | compiler/rustc_hir/src/attrs/data_structures.rs | 3 | ||||
| -rw-r--r-- | compiler/rustc_hir/src/attrs/encode_cross_crate.rs | 1 |
2 files changed, 4 insertions, 0 deletions
diff --git a/compiler/rustc_hir/src/attrs/data_structures.rs b/compiler/rustc_hir/src/attrs/data_structures.rs index bfc7613342a..c565b822619 100644 --- a/compiler/rustc_hir/src/attrs/data_structures.rs +++ b/compiler/rustc_hir/src/attrs/data_structures.rs @@ -565,6 +565,9 @@ pub enum AttributeKind { /// Represents [`#[may_dangle]`](https://std-dev-guide.rust-lang.org/tricky/may-dangle.html). MayDangle(Span), + /// Represents `#[move_size_limit]` + MoveSizeLimit { attr_span: Span, limit_span: Span, limit: usize }, + /// Represents `#[must_use]`. MustUse { span: Span, diff --git a/compiler/rustc_hir/src/attrs/encode_cross_crate.rs b/compiler/rustc_hir/src/attrs/encode_cross_crate.rs index 26929e805a5..4df77c90155 100644 --- a/compiler/rustc_hir/src/attrs/encode_cross_crate.rs +++ b/compiler/rustc_hir/src/attrs/encode_cross_crate.rs @@ -61,6 +61,7 @@ impl AttributeKind { MacroUse { .. } => No, Marker(..) => No, MayDangle(..) => No, + MoveSizeLimit { .. } => No, MustUse { .. } => Yes, Naked(..) => No, NoImplicitPrelude(..) => No, |
