summary refs log tree commit diff
path: root/src/libsyntax/config.rs
AgeCommit message (Collapse)AuthorLines
2016-08-01Avoid processing `feature`s on unconfigured crates.Jeffrey Seyfried-1/+1
2016-06-28cleanup: don't count attributes on an item in a statement position as on the ↵Jeffrey Seyfried-6/+1
statement
2016-06-26Rollup merge of #34316 - jseyfried:refactor_ast_stmt, r=eddybJeffrey Seyfried-10/+3
Refactor away `ast::Decl`, refactor `ast::Stmt`, and rename `ast::ExprKind::Again` to `ast::ExprKind::Continue`.
2016-06-23Move errors from libsyntax to its own crateJonathan Turner-1/+2
2016-06-17Fix falloutJeffrey Seyfried-10/+3
2016-06-16Simplify gated cfg checkingJeffrey Seyfried-60/+48
2016-06-16Auto merge of #34216 - jseyfried:nested_cfg_attr, r=nrcbors-1/+1
Support nested `cfg_attr` attributes Support arbitrarily deeply nested `cfg_attr` attributes (e.g. `#[cfg_attr(foo, cfg_attr(bar, baz))]`). This makes configuration idempotent. Currently, the nighties do not support any `cfg_attr` nesting. Stable and beta support just one level of `cfg_attr` nesting (expect for attributes on macro-expanded nodes, where no nesting is supported). This is a [breaking-change]. For example, the following would break: ```rust macro_rules! m { () => { #[cfg_attr(all(), cfg_attr(all(), cfg(foo)))] fn f() {} } } m!(); fn main() { f() } //~ ERROR unresolved name `f` ``` r? @nrc
2016-06-11Support nested `cfg_attr` attributesJeffrey Seyfried-1/+1
2016-06-11Refactor away the `CfgFolder` trait.Jeffrey Seyfried-34/+18
2016-06-11Forbid `#[test]` attributes on non-optional expressions.Jeffrey Seyfried-1/+1
2016-06-11Strip `#[test]` nodes during `cfg` processing on non-test builds.Jeffrey Seyfried-2/+14
2016-06-09Avoid configuring interpolated items.Jeffrey Seyfried-0/+7
2016-06-02Fix bug in the `syntax::config::StripUnconfigured` folderJeffrey Seyfried-9/+11
2016-05-27Comment methods in `CfgFolder`Jeffrey Seyfried-0/+7
2016-05-27Strip unconfigured items during macro expansionJeffrey Seyfried-7/+12
2016-05-27Process `cfg_attr` attributes on non-optional expressionsJeffrey Seyfried-31/+35
2016-05-26Move cfg_attr processing and stmt/expr attribute gated feature checking into ↵Jeffrey Seyfried-248/+86
`StripUnconfigured`
2016-05-26Implement `CfgFolder` directly instead of passing a closure to `strip_items`Jeffrey Seyfried-27/+14
2016-05-26Refactor `CfgFolder::in_cfg` -> `CfgFolder::configure`Jeffrey Seyfried-45/+29
2016-05-26Introduce `CfgFolder` traitJeffrey Seyfried-19/+32
2016-05-26Refactor the `syntax::config::fold_*` functions into methodsJeffrey Seyfried-147/+81
2016-04-06Move span into `StructField`Vadim Petrochenkov-3/+3
2016-02-11Remove some unnecessary indirection from AST structuresVadim Petrochenkov-17/+14
2016-02-11[breaking-change] don't glob export ast::MetaItem_Oliver 'ker' Schneider-1/+1
2016-02-11[breaking-change] don't glob export ast::Item_ variantsOliver 'ker' Schneider-12/+12
2016-02-11[breaking-change] don't pub export ast::Stmt_ variantsOliver Schneider-1/+1
2016-02-11[breaking-change] don't glob export ast::Expr_ variantsOliver Schneider-2/+2
2016-02-11[breaking-change] don't glob export ast::Decl_ variantsOliver Schneider-1/+1
2015-12-17move error handling from libsyntax/diagnostics.rs to libsyntax/errors/*Nick Cameron-9/+9
Also split out emitters into their own module.
2015-11-26Added stmt_expr_attribute feature gateMarvin Löbel-39/+210
2015-11-26Moved and refactored ThinAttributesMarvin Löbel-1/+1
2015-11-26Add syntax support for attributes on expressions and all syntaxMarvin Löbel-42/+65
nodes in statement position. Extended #[cfg] folder to allow removal of statements, and of expressions in optional positions like expression lists and trailing block expressions. Extended lint checker to recognize lint levels on expressions and locals.
2015-11-10Use deref coercionsSeo Sanghyeon-5/+5
2015-10-25syntax/rustc_front: Simplify VariantData::fieldsVadim Petrochenkov-15/+13
And use VariantData instead of P<VariantData> in Item_ and Variant_
2015-10-13Merge VariantData and VariantData_Vadim Petrochenkov-16/+13
2015-10-13Merge struct fields and struct kindVadim Petrochenkov-5/+14
2015-10-13Dict -> Struct, StructDef -> VariantData, def -> dataVadim Petrochenkov-5/+5
2015-10-13Remove now redundant NodeId from VariantVadim Petrochenkov-2/+1
2015-10-13Decouple structure kinds from NodeIdsVadim Petrochenkov-2/+3
2015-10-13Unify structures and enum variants in ASTVadim Petrochenkov-7/+2
2015-10-09Some cleanup of no longer used AST thingsNick Cameron-2/+2
2015-09-17Remove Visibility field from enum variantsSimonas Kazlauskas-2/+1
Followup on #28440
2015-08-17feature gate `cfg(target_feature)`.Huon Wilson-9/+19
This is theoretically a breaking change, but GitHub search turns up no uses of it, and most non-built-in cfg's are passed via cargo features, which look like `feature = "..."`, and hence can't overlap.
2015-04-21syntax: Remove uses of #[feature(slice_patterns)]Erick Tryzelaar-2/+9
2015-03-11syntax: gather common fields of impl & trait items into their respective types.Eduard Burtescu-21/+2
2015-02-18Replace all uses of `&foo[]` with `&foo[..]` en masse.Niko Matsakis-1/+1
2015-02-09Process cfg_attr right before stripping cfgKeegan McAllister-1/+48
Fixes #22070. Fixes #19372.
2015-02-05cleanup: replace `as[_mut]_slice()` calls with deref coercionsJorge Aparicio-11/+11
2015-01-21syntax: fix fallout of merging ast::ViewItem into ast::Item.Eduard Burtescu-32/+4
2015-01-04Add syntax for negative implementations of traitsFlavio Percoco-2/+2
This commit introduces the syntax for negative implmenetations of traits as shown below: `impl !Trait for Type {}` cc #13231 Part of RFC #3