about summary refs log tree commit diff
path: root/compiler/rustc_attr_data_structures/src
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2025-07-14 12:17:15 +0000
committerbors <bors@rust-lang.org>2025-07-14 12:17:15 +0000
commitcccf075eba88363269e8589ebb8d40874cc542d8 (patch)
treeb1fe89de6c48de27d45435ae644fed25b12c426e /compiler/rustc_attr_data_structures/src
parent64b185eddaa1d7ddf5e0c024be23b9cbba6c1722 (diff)
parent0d69847b3c6961682b5dd09b7e652d25a7ecbdce (diff)
Auto merge of #143919 - Kobzol:rollup-acyaygs, r=Kobzol
Rollup of 10 pull requests

Successful merges:

 - rust-lang/rust#143217 (Port #[link_ordinal] to the new attribute parsing infrastructure)
 - rust-lang/rust#143681 (bootstrap/miri: avoid rebuilds for test builds)
 - rust-lang/rust#143724 (Tidy cleanup)
 - rust-lang/rust#143733 (Change bootstrap's `tool.TOOL_NAME.features` to work on any subcommand)
 - rust-lang/rust#143850 (Compiletest: Simplify {Html,Json}DocCk directive handling)
 - rust-lang/rust#143875 (update issue number for `const_trait_impl`)
 - rust-lang/rust#143881 (Use zero for initialized Once state)
 - rust-lang/rust#143887 (Run bootstrap tests sooner in the `x test` pipeline)
 - rust-lang/rust#143917 (Change "allocated object" to "allocation".)
 - rust-lang/rust#143918 (Tier check cleanup)

r? `@ghost`
`@rustbot` modify labels: rollup
Diffstat (limited to 'compiler/rustc_attr_data_structures/src')
-rw-r--r--compiler/rustc_attr_data_structures/src/attributes.rs3
-rw-r--r--compiler/rustc_attr_data_structures/src/encode_cross_crate.rs1
2 files changed, 4 insertions, 0 deletions
diff --git a/compiler/rustc_attr_data_structures/src/attributes.rs b/compiler/rustc_attr_data_structures/src/attributes.rs
index 41a9e8feaaf..fe1ef52bd1b 100644
--- a/compiler/rustc_attr_data_structures/src/attributes.rs
+++ b/compiler/rustc_attr_data_structures/src/attributes.rs
@@ -297,6 +297,9 @@ pub enum AttributeKind {
     /// Represents `#[link_name]`.
     LinkName { name: Symbol, span: Span },
 
+    /// Represents `#[link_ordinal]`.
+    LinkOrdinal { ordinal: u16, span: Span },
+
     /// Represents [`#[link_section]`](https://doc.rust-lang.org/reference/abi.html#the-link_section-attribute)
     LinkSection { name: Symbol, span: Span },
 
diff --git a/compiler/rustc_attr_data_structures/src/encode_cross_crate.rs b/compiler/rustc_attr_data_structures/src/encode_cross_crate.rs
index b92f0ade3d3..1fa762dc45f 100644
--- a/compiler/rustc_attr_data_structures/src/encode_cross_crate.rs
+++ b/compiler/rustc_attr_data_structures/src/encode_cross_crate.rs
@@ -41,6 +41,7 @@ impl AttributeKind {
             Ignore { .. } => No,
             Inline(..) => No,
             LinkName { .. } => Yes,
+            LinkOrdinal { .. } => No,
             LinkSection { .. } => No,
             LoopMatch(..) => No,
             MacroTransparency(..) => Yes,