From 18607149fbb0836059a96981c78e10ca52d23cd5 Mon Sep 17 00:00:00 2001 From: Alex Crichton Date: Thu, 30 Jul 2015 14:20:36 -0700 Subject: syntax: Add a new unstable #[linked_from] attribute To correctly reexport statically included libraries from a DLL on Windows, the compiler will soon need to have knowledge about what symbols are statically included and which are not. To solve this problem a new unstable `#[linked_from]` attribute is being added and recognized on `extern` blocks to indicate which native library the symbols are coming from. The compiler then keeps track of what the set of FFI symbols are that are included statically. This information will be used in a future commit to configure how we invoke the linker on Windows. --- src/libsyntax/feature_gate.rs | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/libsyntax') diff --git a/src/libsyntax/feature_gate.rs b/src/libsyntax/feature_gate.rs index 60a5730a3da..87149ff81da 100644 --- a/src/libsyntax/feature_gate.rs +++ b/src/libsyntax/feature_gate.rs @@ -85,6 +85,7 @@ const KNOWN_FEATURES: &'static [(&'static str, &'static str, Status)] = &[ ("on_unimplemented", "1.0.0", Active), ("simd_ffi", "1.0.0", Active), ("allocator", "1.0.0", Active), + ("linked_from", "1.3.0", Active), ("if_let", "1.0.0", Accepted), ("while_let", "1.0.0", Accepted), @@ -269,6 +270,10 @@ pub const KNOWN_ATTRIBUTES: &'static [(&'static str, AttributeType)] = &[ "the `#[fundamental]` attribute \ is an experimental feature")), + ("linked_from", Gated("linked_from", + "the `#[linked_from]` attribute \ + is an experimental feature")), + // FIXME: #14408 whitelist docs since rustdoc looks at them ("doc", Whitelisted), -- cgit 1.4.1-3-g733a5