about summary refs log tree commit diff
path: root/compiler/rustc_attr_data_structures
diff options
context:
space:
mode:
authorFolkert de Vries <folkert@folkertdev.nl>2025-06-09 20:08:52 +0200
committerFolkert de Vries <folkert@folkertdev.nl>2025-06-18 12:37:08 +0200
commit1fdf2b562070ec98c5b32ee67b8c6d8145127a6e (patch)
treeb03e6e19001df8984537f2843f246c8453c1bcf6 /compiler/rustc_attr_data_structures
parent1bb335244c311a07cee165c28c553c869e6f64a9 (diff)
downloadrust-1fdf2b562070ec98c5b32ee67b8c6d8145127a6e.tar.gz
rust-1fdf2b562070ec98c5b32ee67b8c6d8145127a6e.zip
add `#[align]` attribute
Right now it's used for functions with `fn_align`, in the future it will
get more uses (statics, struct fields, etc.)
Diffstat (limited to 'compiler/rustc_attr_data_structures')
-rw-r--r--compiler/rustc_attr_data_structures/src/attributes.rs3
1 files changed, 3 insertions, 0 deletions
diff --git a/compiler/rustc_attr_data_structures/src/attributes.rs b/compiler/rustc_attr_data_structures/src/attributes.rs
index d4c43456049..cdc01dc6c91 100644
--- a/compiler/rustc_attr_data_structures/src/attributes.rs
+++ b/compiler/rustc_attr_data_structures/src/attributes.rs
@@ -182,6 +182,9 @@ impl Deprecation {
 #[derive(Clone, Debug, HashStable_Generic, Encodable, Decodable, PrintAttribute)]
 pub enum AttributeKind {
     // tidy-alphabetical-start
+    /// Represents `#[align(N)]`.
+    Align { align: Align, span: Span },
+
     /// Represents `#[rustc_allow_const_fn_unstable]`.
     AllowConstFnUnstable(ThinVec<Symbol>),