Module syntax::feature_gate[][src]

Feature gating

This module implements the gating necessary for preventing certain compiler features from being used by default. This module will crawl a pre-expanded AST to ensure that there are no features which are used that are not enabled.

Features are enabled in programs via the crate-level attributes of #![feature(...)] with a comma-separated list of features.

For the purpose of future feature-tracking, once code for detection of feature gate usage is added, do not remove it again even once the feature becomes stable.

Structs

Features

A set of features to be used by later passes.

GatedCfg

Enums

AttributeGate
AttributeType
GateIssue
GateStrength
Stability
UnstableFeatures

Constants

BUILTIN_ATTRIBUTES
EXPLAIN_ALLOW_INTERNAL_UNSAFE
EXPLAIN_ALLOW_INTERNAL_UNSTABLE
EXPLAIN_ASM
EXPLAIN_CONCAT_IDENTS
EXPLAIN_CUSTOM_DERIVE
EXPLAIN_DEPR_CUSTOM_DERIVE
EXPLAIN_DERIVE_UNDERSCORE
EXPLAIN_GLOBAL_ASM
EXPLAIN_LITERAL_MATCHER
EXPLAIN_LOG_SYNTAX
EXPLAIN_MACROS_IN_EXTERN
EXPLAIN_MACRO_AT_MOST_ONCE_REP
EXPLAIN_PROC_MACROS_IN_EXTERN
EXPLAIN_STMT_ATTR_SYNTAX
EXPLAIN_TRACE_MACROS
EXPLAIN_UNSIZED_TUPLE_COERCION
EXPLAIN_VIS_MATCHER

Functions

check_attribute
check_crate
deprecated_attributes
emit_feature_err
feature_err
find_lang_feature_accepted_version
get_features
is_builtin_attr