about summary refs log tree commit diff
path: root/src/libsyntax/feature_gate.rs
AgeCommit message (Collapse)AuthorLines
2019-05-14Fix incremental compilation of cdylib emitting spurious unused_attributes lintOliver Scherer-1/+1
2019-05-13add impl_trait_in_bindings to INCOMPLETE_FEATURESPulkit Goyal-0/+1
impl_trait_in_bindings is not yet complete and can lead to compiler crashes. Fixes #60764.
2019-05-13Return a `Symbol` from `name_or_empty` functions.Nicholas Nethercote-3/+3
2019-05-13Remove the equality operation between `Symbol` and strings.Nicholas Nethercote-9/+9
And also the equality between `Path` and strings, because `Path` is made up of `Symbol`s.
2019-05-13Pass a `Symbol` to `check_name`, `emit_feature_err`, and related functions.Nicholas Nethercote-95/+96
2019-05-13Rename `syntax::symbol::symbols` as `syntax::symbol::sym`.Nicholas Nethercote-132/+132
Because it's going to be used a lot.
2019-05-07Auto merge of #60586 - cramertj:await, r=oli-obkbors-0/+18
Implement built-in await syntax Adds support for .await under the existing async_await feature gate. Moves macro-like await! syntax to the await_macro feature gate. Removes support for `await` as a non-keyword under the `async_await` feature. This new syntax is not final, but is the consensus solution proposed by the lang team, as explained in https://boats.gitlab.io/blog/post/await-decision/ Fix https://github.com/rust-lang/rust/issues/51719 Fix https://github.com/rust-lang/rust/issues/51751 Fix https://github.com/rust-lang/rust/issues/60016
2019-05-07Implement built-in await syntaxTaylor Cramer-0/+18
Adds support for .await under the existing async_await feature gate. Moves macro-like await! syntax to the await_macro feature gate. Removes support for `await` as a non-keyword under the `async_await` feature.
2019-05-04Rename 'no tracking issue START' to fit better with tidy.Mazdak Farrokhzad-8/+8
2019-05-04Enforce sorting of accepted and removed features.Mazdak Farrokhzad-8/+31
2019-05-02Group and sort feature_gate.rsAlexey Shmalko-11/+22
2019-04-30Rollup merge of #60362 - Centril:cleanup-declare-features-active, r=oli-obkMazdak Farrokhzad-183/+252
Cleanup 'active' declare_features! with uniform style + sorting. r? @oli-obk (added the FIXME you wanted) cc https://github.com/rust-lang/rust/pull/60354 cc https://github.com/rust-lang/rust/issues/60361
2019-04-30Rollup merge of #60354 - Centril:cleanup-declare-features-accepted, r=oli-obkMazdak Farrokhzad-56/+73
Cleanup declare_features! for 'accepted' with a uniform style + sort them r? @oli-obk cc https://github.com/rust-lang/rust/pull/60362 cc https://github.com/rust-lang/rust/issues/60361
2019-04-30Cleanup 'active' declare_features! with uniform style + sorting.Mazdak Farrokhzad-183/+252
2019-04-28Cleanup declare_features! for 'accepted' with a uniform style + sort them.Mazdak Farrokhzad-56/+73
2019-04-28Float 'incomplete_features' out to a const for visibility.Mazdak Farrokhzad-6/+9
2019-04-26Rollup merge of #60289 - tmandry:allow-features-include-std, r=cramertjMazdak Farrokhzad-17/+17
Make `-Z allow-features` work for stdlib features r? @cramertj
2019-04-25Make `-Z allow-features` work for stdlib featuresTyler Mandry-17/+17
2019-04-25Add feature-gate for f16c target featuregnzlbg-0/+1
2019-04-21Enable migrate mode by default on the 2015 editionMatthew Jasper-3/+1
This also fully stabilizes two-phase borrows on all editions
2019-04-20Check async in trait methodsvarkor-0/+3
2019-04-20Fix additional variadic typosvarkor-1/+1
2019-04-20Fix typo in variadic C function warningvarkor-1/+1
2019-04-20Feature gate async fn methodsvarkor-19/+13
2019-04-17whitelist rtm x86 cpu featuretyler-0/+1
2019-04-15Preallocate BUILTIN_ATTRIBUTES symbols and use a hash map instead of loopingJohn Kåre Alsaker-392/+492
2019-04-15Make check_name genericJohn Kåre Alsaker-12/+12
2019-04-15Use a proc macro to declare preallocated symbolsJohn Kåre Alsaker-14/+14
2019-04-11Reword tracking issue noteEsteban Küber-2/+5
2019-04-10Tweak unstable diagnostic outputEsteban Küber-23/+41
2019-03-29Whitelist rustc_layout_scalar_valid_range_{start,end} so incr comp does not ↵Felix S. Klock II-0/+14
flag them as unused.
2019-03-29Whitelist `rustc_on_unimplemented` to avoid erroneous flagging as an unused ↵Felix S. Klock II-1/+1
attribute.
2019-03-26Rollup merge of #59150 - estebank:type-ascription, r=varkorMazdak Farrokhzad-2/+6
Expand suggestions for type ascription parse errors Fix #51222. CC #48016, #47666, #54516, #34255.
2019-03-22Hide "type ascription is experimental error" unless it's the only oneEsteban Küber-2/+6
In order to minimize the verbosity of common syntax errors that are parsed as type ascription, hide the feature gate error unless there are no other errors being emitted by the parser.
2019-03-17Make meta-item API compatible with `LocalInternedString::get` soundness fixVadim Petrochenkov-8/+8
2019-03-16Refactor away `NestedMetaItemKind`Vadim Petrochenkov-9/+9
Remove methods `Attribute::span` and `MetaItem::span` duplicating public fields
2019-03-16syntax: Do not accidentally treat multi-segment meta-items as single-segmentVadim Petrochenkov-17/+16
2019-03-16Rollup merge of #59169 - tmandry:allow-features-flag, r=cramertjkennytm-1/+10
Add `-Z allow_features=...` flag Adds a compiler option to allow only whitelisted features. For projects on nightly that want to prevent feature-creep (and maybe, someday, move off of nightly). Not being able to enforce this has been a problem on Fuchsia and at other big companies. This doesn't support filtering edition feature flags, but someone is welcome to add that if they need it.
2019-03-15rustc: rename item_path to def_path (except the module in ty).Eduard-Mihai Burtescu-1/+1
2019-03-14Add `-Z allow_features=...` flagTyler Mandry-1/+10
2019-03-09Rollup merge of #58762 - petrochenkov:unwind, r=Mark-SimulacrumMazdak Farrokhzad-1/+1
Mention `unwind(aborts)` in diagnostics for `#[unwind]` Simplify input validation for `#[unwind]`, add tests cc https://github.com/rust-lang/rust/issues/58760 r? @Mark-Simulacrum
2019-02-28Auto merge of #57760 - dlrobertson:varargs1, r=alexregbors-0/+12
Support defining C compatible variadic functions ## Summary Add support for defining C compatible variadic functions in unsafe rust with `extern "C"` according to [RFC 2137]. ## Details ### Parsing When parsing a user defined function that is `unsafe` and `extern "C"` allow variadic signatures and inject a "spoofed" `VaList` in the new functions signature. This allows the user to interact with the variadic arguments via a `VaList` instead of manually using `va_start` and `va_end` (See [RFC 2137] for details). ### Codegen When running codegen for a variadic function, remove the "spoofed" `VaList` from the function signature and inject `va_start` when the arg local references are created for the function and `va_end` on return. ## TODO - [x] Get feedback on injecting `va_start/va_end` in MIR vs codegen - [x] Properly inject `va_end` - It seems like it should be possible to inject `va_end` on the `TerminatorKind::Return`. I just need to figure out how to get the `LocalRef` here. - [x] Properly call Rust defined C variadic functions in Rust - The spoofed `VaList` causes problems here. Related to: #44930 r? @ghost [RFC 2137]: https://github.com/rust-lang/rfcs/blob/master/text/2137-variadic.md
2019-02-27Add c_variadic language feature itemDan Robertson-0/+12
2019-02-27Rollup merge of #58761 - Mark-Simulacrum:add-feature-gate-unwind, r=CentrilMazdak Farrokhzad-2/+2
Add tracking issue for the unwind attribute cc https://github.com/rust-lang/rust/issues/58760
2019-02-27Rollup merge of #58678 - doctorn:refuse-async-fn-2015-edition, r=varkorMazdak Farrokhzad-1/+1
Deny `async fn` in 2015 edition This commit prevents code using `async fn` from being compiled in Rust 2015 edition. Compiling code of the form: ```rust async fn foo() {} ``` Will now result in the error: ``` error[E0670]: `async fn` is not permitted in the 2015 edition --> async.rs:1:1 | 1 | async fn foo() {} | ^^^^^ error: aborting due to error For more information about an error, try `rustc --explain E0670`. ``` This resolves #58652 and also resolves #53714. r? @varkor
2019-02-27Mention `unwind(aborts)` in diagnostics for `#[unwind]`Vadim Petrochenkov-1/+1
Simplify input validation for `#[unwind]`, add tests
2019-02-26Add tracking issue for the unwind attribute.Mark Rousskov-2/+2
2019-02-25Stabilize `unrestricted_attribute_tokens`Vadim Petrochenkov-11/+7
2019-02-24Deny `async fn` in 2015 editionNathan Corbyn-1/+1
Fix style issues and update diagnostic messages Update src/librustc_passes/diagnostics.rs Co-Authored-By: doctorn <me@nathancorbyn.com> Deny nested `async fn` in Rust 2015 edition Deny nested `async fn` in Rust 2015 edition Deny nested `async fn` in Rust 2015 edition
2019-02-23Correct error messagegnzlbg-1/+1