Module syntax::attr [] [src]

🔬 This is a nightly-only experimental API. (rustc_private)

this crate is being loaded from the sysroot, an unstable location; did you mean to load this crate from crates.io via Cargo.toml instead?

Reexports

pub use self::StabilityLevel::*;
pub use self::ReprAttr::*;
pub use self::IntType::*;

Structs

Deprecation [
Experimental
]
RustcConstUnstable [
Experimental
]
RustcDeprecation [
Experimental
]
Stability [
Experimental
]

Represents the #[stable], #[unstable], #[rustc_{deprecated,const_unstable}] attributes.

Enums

InlineAttr [
Experimental
]
IntType [
Experimental
]
ReprAttr [
Experimental
]
StabilityLevel [
Experimental
]

The available stability levels.

Traits

HasAttrs [
Experimental
]

Functions

cfg_matches [
Experimental
]

Tests if a cfg-pattern matches the cfg set

contains_feature_attr [
Experimental
]

Check if attrs contains an attribute like #![feature(feature_name)]. This will not perform any "sanity checks" on the form of the attributes.

contains_name [
Experimental
]
eval_condition [
Experimental
]

Evaluate a cfg-like condition (with any and all), using eval to evaluate individual items.

find_by_name [
Experimental
]
find_crate_name [
Experimental
]
find_deprecation [
Experimental
]

Find the deprecation attribute. None if none exists.

find_inline_attr [
Experimental
]

Determine what #[inline] attribute is present in attrs, if any.

find_repr_attrs [
Experimental
]

Parse #[repr(...)] forms.

find_stability [
Experimental
]

Find the first stability attribute. None if none exists.

first_attr_value_str_by_name [
Experimental
]
is_known [
Experimental
]
is_used [
Experimental
]
list_contains_name [
Experimental
]
mark_known [
Experimental
]
mark_used [
Experimental
]
mk_attr_id [
Experimental
]
mk_attr_inner [
Experimental
]

Returns an inner attribute with the given value.

mk_attr_outer [
Experimental
]

Returns an outer attribute with the given value.

mk_list_item [
Experimental
]
mk_list_word_item [
Experimental
]
mk_name_value_item [
Experimental
]
mk_name_value_item_str [
Experimental
]
mk_spanned_attr_inner [
Experimental
]

Returns an inner attribute with the given value and span.

mk_spanned_attr_outer [
Experimental
]

Returns an outer attribute with the given value and span.

mk_spanned_list_item [
Experimental
]
mk_spanned_name_value_item [
Experimental
]
mk_spanned_word_item [
Experimental
]
mk_sugared_doc_attr [
Experimental
]
mk_word_item [
Experimental
]
requests_inline [
Experimental
]

True if #[inline] or #[inline(always)] is present in attrs.