about summary refs log tree commit diff
path: root/src/libsyntax/feature_gate.rs
AgeCommit message (Collapse)AuthorLines
2018-06-12Stabilize #[repr(transparent)]Simon Sapin-8/+2
Tracking issue FCP: https://github.com/rust-lang/rust/issues/43036#issuecomment-394094318 Reference PR: https://github.com/rust-lang-nursery/reference/pull/353
2018-06-11Stabilize the #[global_allocator] attributeSimon Sapin-7/+3
Fixes https://github.com/rust-lang/rust/issues/27389
2018-06-08Rollup merge of #51298 - Dylan-DPC:stabilise/termination-test, r=nikomatsakisMark Rousskov-3/+2
Stabilize unit tests with non-`()` return type References #48854
2018-06-08Rollup merge of #51283 - ↵kennytm-1/+1
kennytm:fix-51279-preempt-the-warning-song-and-dance, r=nikomatsakis Deny #[cfg] and #[cfg_attr] on generic parameters. Fix #51279. Attributes on generic parameters are not expanded, meaning `#[cfg]`, `#[cfg_attr]` and attribute proc macros are entirely ignored on them. This PR makes using the first two attributes an error, because if they are correctly expanded will affect the AST and change code behavior. I'm beta-nominating this, because generic parameter attributes are stabilizing in 1.27, and if we did not reserve their usage, we may never be able to repurpose the meaning of these attributes in the Rust 2015 edition.
2018-06-05flag changed to nonedylan_DPC-1/+1
2018-06-04Put doc keyword behind feature flagGuillaume Gomez-0/+8
2018-06-04Merge branch 'master' into stabilise/termination-testDylan DPC-0/+8
2018-06-03implement #[panic_implementation]Jorge Aparicio-0/+9
2018-06-02fixed feature gate to right placedylan_DPC-2/+2
2018-06-02Stabilize unit tests with non-`()` return typedylan_DPC-3/+3
2018-06-02Deny #[cfg] and #[cfg_attr] on generic parameters.kennytm-1/+1
2018-05-27Ensure every unstable feature has a tracking issue.kennytm-22/+24
2018-05-27Auto merge of #51066 - est31:master, r=sfacklerbors-1/+1
Point to the current box syntax tracking issue The issue was used for both box syntax as well as placement new. It got closed due to placement new being unapproved. So a new one got created for box syntax, yet neither the unstable book nor feature_gate.rs got updated. We are doing this now. r? @aidanhs
2018-05-26Point to the current box syntax tracking issueest31-1/+1
The issue was used for both box syntax as well as placement new. It got closed due to placement new being unapproved. So a new one got created for box syntax, yet neither the unstable book nor feature_gate.rs got updated. We are doing this now.
2018-05-26Auto merge of #51052 - nikomatsakis:obsolete-arrow, r=petrochenkovbors-0/+3
restore emplacement syntax (obsolete) Fix https://github.com/rust-lang/rust/issues/50832 r? @petrochenkov
2018-05-25Implement outlives requirements inference for dyn and projections.toidiu-0/+6
Add tests, documentation and attr for feature.
2018-05-24restore emplacement syntax (obsolete)Niko Matsakis-0/+3
2018-05-22Allow let bindings in const fn and constantsOliver Schneider-0/+3
2018-05-21Remove rustc_serialize_exclude_nullManish Goregaokar-5/+0
2018-05-20Auto merge of #50820 - alexcrichton:no-modules, r=petrochenkovbors-0/+1
rustc: Disallow modules and macros in expansions This commit feature gates generating modules and macro definitions in procedural macro expansions. Custom derive is exempt from this check as it would be a large retroactive breaking change (#50587). It's hoped that we can hopefully stem the bleeding to figure out a better solution here before opening up the floodgates. The restriction here is specifically targeted at surprising hygiene results [1] that result in non-"copy/paste" behavior. Hygiene and procedural macros is intended to be avoided as much as possible for Macros 1.2 by saying everything is "as if you copy/pasted the code", but modules and macros are sort of weird exceptions to this rule that aren't fully fleshed out. [1]: https://github.com/rust-lang/rust/issues/50504#issuecomment-387734625 cc #50504
2018-05-18rustc: Disallow modules and macros in expansionsAlex Crichton-0/+1
This commit feature gates generating modules and macro definitions in procedural macro expansions. Custom derive is exempt from this check as it would be a large retroactive breaking change (#50587). It's hoped that we can hopefully stem the bleeding to figure out a better solution here before opening up the floodgates. The restriction here is specifically targeted at surprising hygiene results [1] that result in non-"copy/paste" behavior. Hygiene and procedural macros is intended to be avoided as much as possible for Macros 1.2 by saying everything is "as if you copy/pasted the code", but modules and macros are sort of weird exceptions to this rule that aren't fully fleshed out. [1]: https://github.com/rust-lang/rust/issues/50504#issuecomment-387734625 cc #50504
2018-05-17Rename trans to codegen everywhere.Irina Popa-2/+2
2018-05-16Add feature gate label_break_valueest31-0/+9
2018-05-15Feature gate trivial boundsMatthew Jasper-0/+3
2018-05-13stabilize :lifetimeAlex Burka-6/+2
2018-05-13Macros: Add a 'literal' fragment specifierDan Aloni-0/+6
Implements RFC 1576. See: https://github.com/rust-lang/rfcs/blob/master/text/1576-macros-literal-matcher.md Changes are mostly in libsyntax, docs, and tests. Feature gate is enabled for 1.27.0. Many thanks to Vadim Petrochenkov for following through code reviews and suggestions. Example: ````rust macro_rules! test_literal { ($l:literal) => { println!("literal: {}", $l); }; ($e:expr) => { println!("expr: {}", $e); }; } fn main() { let a = 1; test_literal!(a); test_literal!(2); test_literal!(-3); } ``` Output: ``` expr: 1 literal: 2 literal: -3 ```
2018-05-12rustc: Allow an edition's feature on that editionAlex Crichton-41/+46
This commit fixes a hard error where the `#![feature(rust_2018_preview)]` feature was forbidden to be mentioned when the `--edition 2018` flag was passed. This instead silently accepts that feature gate despite it not being necessary. It's intended that this will help ease the transition into the 2018 edition as users will, for the time being, start off with the `rust_2018_preview` feature and no longer immediately need to remove it. Closes #50662
2018-05-10Remove `nll` from `rust_2018_preview`Alex Crichton-1/+1
NLL isn't quite ready yet so gonna hold off on inserting it into the preview.
2018-05-04Make extern_absolute_paths only work on the new editionManish Goregaokar-2/+4
2018-05-04Make --edition imply the preview flagManish Goregaokar-0/+6
2018-05-04Add catch and proc macros to the edition (fixes #50443)Manish Goregaokar-2/+2
2018-05-02fix testsflip1995-2/+2
2018-05-02make it compile againflip1995-8/+24
2018-05-02Gate tool_attributes featureSeiichi Uchida-1/+4
2018-05-02Remove Option from the return type of Attribute::name()Seiichi Uchida-1/+1
2018-05-01Auto merge of #49982 - petrochenkov:noreex, r=alexcrichtonbors-43/+40
Remove unstable `macro_reexport` It's subsumed by `feature(use_extern_macros)` and `pub use` cc https://github.com/rust-lang/rust/issues/35896 closes https://github.com/rust-lang/rust/issues/29638 closes https://github.com/rust-lang/rust/issues/38951
2018-05-01Auto merge of #49789 - petrochenkov:prelext, r=nikomatsakisbors-1/+4
Module experiments: Add one more prelude layer for extern crate names passed with `--extern` Implements one item from https://internals.rust-lang.org/t/the-great-module-adventure-continues/6678/183 When some name is looked up in lexical scope (`name`, i.e. not module-relative scope `some_mod::name` or `::name`), it's searched roughly in the next order: - local variables - items in unnamed blocks - items in the current module - :sparkles: NEW! :sparkles: crate names passed with `--extern` ("extern prelude") - standard library prelude (`Vec`, `drop`) - language prelude (built-in types like `u8`, `str`, etc) The last two layers contain a limited set of names controlled by us and not arbitrary user-defined names like upper layers. We want to be able to add new names into these two layers without breaking user code, so "extern prelude" names have higher priority than std prelude and built-in types. This is a one-time breaking change, that's why it would be nice to run this through crater. Practical impact is expected to be minimal though due to stylistic reasons (there are not many `Uppercase` crates) and due to the way how primitive types are resolved (https://github.com/rust-lang/rust/pull/32131).
2018-05-01Give removal reasons to removed featuresVadim Petrochenkov-36/+40
2018-05-01Remove `macro_reexport`Vadim Petrochenkov-9/+2
It's subsumed by `feature(use_extern_macros)` and `pub use`
2018-04-28stabilize `#[must_use]` for functions and must-use operatorsZack M. Davis-19/+3
This is in the matter of RFC 1940 and tracking issue #43302.
2018-04-28Rollup merge of #49968 - christianpoveda:stabilize_dyn, r=nikomatsakiskennytm-7/+2
Stabilize dyn trait This PR stabilizes RFC 2113. I followed the [stabilization guide](https://forge.rust-lang.org/stabilization-guide.html). Related issue: https://github.com/rust-lang/rust/issues/49218
2018-04-27fixed rustc version for dyn_traitChristian Poveda-1/+1
2018-04-27stop requiring the feature-gate to use dyn_traitChristian Poveda-7/+2
2018-04-27Add one more prelude layer for extern crate names passed with `--extern`Vadim Petrochenkov-1/+4
2018-04-26rustc_target: move in syntax::abi and flip dependency.Irina Popa-1/+1
2018-04-24Auto merge of #50096 - alexcrichton:less-simd-warnings, r=michaelwoeristerbors-1/+1
Tweak some warnings around #[target_feature] This commit fixes up some issues discovered when getting the `stdsimd` crate's CI compiling again.
2018-04-24Rollup merge of #49985 - zackmdavis:0, r=estebankkennytm-4/+3
don't see issue #0 The unstable-feature attribute requires an issue (neglecting it is E0547), which gets used in the error messages. Unfortunately, there are some cases where "0" is apparently used a placeholder where no issue exists, directing the user to see the (nonexistent) issue #0. (It would have been better to either let `issue` be optional—compare to how issue is an `Option<u32>` in the feature-gate declarations in libsyntax/feature-gate.rs—or actually require that an issue be created.) Rather than endeavoring to change how `#[unstable]` works at this time (given competing contributor and reviewer priorities), this simple patch proposes the less-ambitious solution of just not adding the "(see issue)" note when the number is zero. Resolves #49983.
2018-04-23Auto merge of #49368 - matthewjasper:feature-gate-where-clause, r=nikomatsakisbors-2/+6
Feature gate where clauses on associated types Fixes #49365. Requires crater: these have been usable since 1.24.
2018-04-22Auto merge of #49757 - GuillaumeGomez:never-search, r=QuietMisdreavusbors-0/+7
Add specific never search Fixes #49529. r? @QuietMisdreavus
2018-04-22Add tracking issue number for doc alias featureGuillaume Gomez-1/+1