about summary refs log tree commit diff
path: root/compiler/rustc_attr_parsing/src/attributes/link_attrs.rs
diff options
context:
space:
mode:
authorJana Dönszelmann <jana@donsz.nl>2025-08-16 18:04:58 +0200
committerJana Dönszelmann <jana@donsz.nl>2025-08-21 13:15:30 +0200
commit2158e2d4d7b2722325de01530296c4e93297c06f (patch)
treed18a87ad2bc0cdb0fd5cabf8f59ab2eb6d7beb7f /compiler/rustc_attr_parsing/src/attributes/link_attrs.rs
parent9be8effb3f7636521d0d177fe23504bd69094ba3 (diff)
downloadrust-2158e2d4d7b2722325de01530296c4e93297c06f.tar.gz
rust-2158e2d4d7b2722325de01530296c4e93297c06f.zip
refactor target checking, move out of context.rs and rename MaybeWarn to Policy
Diffstat (limited to 'compiler/rustc_attr_parsing/src/attributes/link_attrs.rs')
-rw-r--r--compiler/rustc_attr_parsing/src/attributes/link_attrs.rs8
1 files changed, 6 insertions, 2 deletions
diff --git a/compiler/rustc_attr_parsing/src/attributes/link_attrs.rs b/compiler/rustc_attr_parsing/src/attributes/link_attrs.rs
index 552b9dfabc2..80e1faebf14 100644
--- a/compiler/rustc_attr_parsing/src/attributes/link_attrs.rs
+++ b/compiler/rustc_attr_parsing/src/attributes/link_attrs.rs
@@ -7,10 +7,14 @@ use rustc_span::{Span, Symbol, sym};
 use crate::attributes::{
     AttributeOrder, NoArgsAttributeParser, OnDuplicate, SingleAttributeParser,
 };
-use crate::context::MaybeWarn::Allow;
-use crate::context::{ALL_TARGETS, AcceptContext, AllowedTargets, Stage, parse_single_integer};
+use crate::context::{AcceptContext, Stage};
 use crate::parser::ArgParser;
 use crate::session_diagnostics::{LinkOrdinalOutOfRange, NullOnLinkSection};
+use crate::target_checking::Policy::Allow;
+use crate::target_checking::{ALL_TARGETS, AllowedTargets};
+
+use super::util::parse_single_integer;
+
 pub(crate) struct LinkNameParser;
 
 impl<S: Stage> SingleAttributeParser<S> for LinkNameParser {