about summary refs log tree commit diff
path: root/compiler/rustc_feature/src/active.rs
AgeCommit message (Collapse)AuthorLines
2022-02-24Remove in-band lifetimesMichael Goulet-2/+0
2022-02-19Rollup merge of #93658 - cchiw:issue-77443-fix, r=joshtriplettMatthias Krüger-2/+0
Stabilize `#[cfg(panic = "...")]` [Stabilization PR](https://rustc-dev-guide.rust-lang.org/stabilization_guide.html#stabilization-pr) for #77443
2022-02-17Rollup merge of #93337 - Amanieu:asm_tracking, r=tmiaskoMatthias Krüger-4/+4
Update tracking issue numbers for inline assembly sub-features The main tracking issue for inline assembly is [closed](https://github.com/rust-lang/rust/issues/72016#issuecomment-1022332954), further tracking of the remaining sub-features has been moved to separate tracking issues.
2022-02-16Destabilize cfg(target_has_atomic_load_store = ...)Mark Rousskov-0/+2
This was not intended to be stabilized yet.
2022-02-14Update unsafe_pin_internals unstable version.Mara Bos-1/+1
2022-02-14Mark `unsafe_pin_internals` as `incomplete`.Daniel Henry-Mantilla-0/+3
This thus still makes it technically possible to enable the feature, and thus to trigger UB without `unsafe`, but this is fine since incomplete features are known to be potentially unsound (labelled "may not be safe"). This follows from the discussion at https://github.com/rust-lang/rust/pull/93176#discussion_r799413561
2022-02-10updating the feature-gate listing and do not require the feature-gate to use ↵Charisee-2/+0
the feature
2022-02-10Rollup merge of #93824 - Amanieu:stable_cfg_target_has_atomic, r=davidtwcoMatthias Krüger-2/+2
Stabilize cfg_target_has_atomic `target_has_atomic_equal_alignment` is now tracked separately in #93822. Closes #32976
2022-02-09Rollup merge of #91504 - cynecx:used_retain, r=nikicMatthias Krüger-0/+2
`#[used(linker)]` attribute See https://github.com/dtolnay/linkme/issues/41#issuecomment-927255631.
2022-02-09Stabilize cfg_target_has_atomicAmanieu d'Antras-2/+2
Closes #32976
2022-02-09Add tracking issueNikita Popov-1/+1
2022-02-07Rollup merge of #93682 - ↵Mara Bos-1/+1
PatchMixolydic:where-in-the-world-is-const_fn_trait_bound, r=oli-obk Update tracking issue for `const_fn_trait_bound` It previously pointed to #57563, the conglomerate issue for `const fn` (presumably under the feature gate `const_fn`). This tracking issue doesn't mention anything about `const_fn_trait_bound`(the only occurrence of "trait bound" is for the now-removed `?const Trait` syntax), which can be confusing to people who want to find out more about trait bounds on `const fn`s. This pull request changes the tracking issue to one meant specifically for `const_fn_trait_bound`, #93706, which can help collect information on this feature's stabilization and point users towards `const_trait_impl` if they're looking for const-in-const-contexts trait bounds. Fixes #93679. `````@rustbot````` modify labels +A-const-fn +F-const_trait_impl
2022-02-07Rollup merge of #93416 - name1e5s:chore/remove_allow_fail, r=m-ou-seMara Bos-2/+0
remove `allow_fail` test flag close #93345
2022-02-07add tests and fix commentscynecx-2/+2
2022-02-06`#[used(linker)]` attribute (https://github.com/dtolnay/linkme/issues/41)cynecx-0/+2
2022-02-06Fix tracking issue for `const_fn_trait_bound`Ruby Lazuli-1/+1
It previously pointed to #57563, the conglomerate issue for `const fn` (presumably under the feature gate `const_fn`). `const_fn_trait_bounds` weren't mentioned here, so this commit changes its tracking issue to a new one.
2022-01-31Move overlap_mode into trait level attribute + feature flagSantiago Pastorino-0/+3
2022-01-28remove allow_fail test flagyuhaixin.hx-2/+0
2022-01-26Update tracking issue numbers for inline assembly sub-featuresAmanieu d'Antras-4/+4
2022-01-18Formally implement let chainsCaio-1/+1
2022-01-17Add term to ExistentialProjectionkadmin-0/+2
Also prevent ICE when adding a const in associated const equality.
2021-12-14Stabilize `destructuring_assignment`Jacob Pratt-2/+0
2021-12-10remove feature gate and cleanup codeEllen-6/+0
2021-12-03add `unwind_asm` feature gate for `may_unwind` optioncynecx-0/+2
2021-11-24Rollup merge of #90420 - GuillaumeGomez:rustdoc-internals-feature, r=camelidGuillaume Gomez-4/+2
Create rustdoc_internals feature gate As suggested by ``@camelid`` [here](https://github.com/rust-lang/rust/pull/90398#issuecomment-955093851), since `doc_keyword` and `doc_primitive` aren't meant to be stabilized, we could put them behind a same feature flag. This is pretty much what it would look like (needs to update the tests too). The tracking issue is https://github.com/rust-lang/rust/issues/90418. What do you think ``@rust-lang/rustdoc`` ?
2021-11-24Create rustdoc_internals feature gateGuillaume Gomez-4/+2
2021-11-22`#![feature(inline_const)]` is no longer incompleteGary Guo-1/+1
2021-11-22Split inline const to two feature gatesGary Guo-0/+2
2021-11-15Alphabetize language featuresJacob Pratt-479/+324
This should significantly reduce the frequency of merge conflicts.
2021-11-15Stabilize format_args_captureJosh Triplett-3/+0
Works as expected, and there are widespread reports of success with it, as well as interest in it.
2021-11-13Auto merge of #89551 - jhpratt:stabilize-const_raw_ptr_deref, r=oli-obkbors-3/+0
Stabilize `const_raw_ptr_deref` for `*const T` This stabilizes dereferencing immutable raw pointers in const contexts. It does not stabilize `*mut T` dereferencing. This is behind the same feature gate as mutable references. closes https://github.com/rust-lang/rust/issues/51911
2021-11-07Add features gates for experimental asm featuresAmanieu d'Antras-0/+9
2021-11-06Stabilize `const_raw_ptr_deref` for `*const T`Jacob Pratt-3/+0
This stabilizes dereferencing immutable raw pointers in const contexts. It does not stabilize `*mut T` dereferencing. This is placed behind the `const_raw_mut_ptr_deref` feature gate.
2021-11-02Rollup merge of #90502 - GuillaumeGomez:split-doc-cfg-feature, r=jyn514Matthias Krüger-0/+3
Split doc_cfg and doc_auto_cfg features Part of #90497. With this feature, `doc_cfg` won't pick up items automatically anymore. cc `@Mark-Simulacrum` r? `@jyn514`
2021-11-02Rollup merge of #90472 - joshtriplett:clarify-feature-acceptance, r=jyn514Matthias Krüger-1/+5
Clarify what to do with accepted feature gates The documentation only referenced `removed.rs`, but feature gates for accepted features move to `accepted.rs`.
2021-11-02Split doc_cfg and doc_auto_cfg featuresGuillaume Gomez-0/+3
2021-11-02Add link to documentation about feature gatesJosh Triplett-0/+3
2021-11-01Clarify what to do with accepted feature gatesJosh Triplett-1/+2
The documentation only referenced `removed.rs`, but feature gates for accepted features move to `accepted.rs`.
2021-10-30stabilize `relaxed_struct_unsize`lcnr-3/+0
2021-10-23Rollup merge of #89730 - crlf0710:type_changing_feature, r=jackh726Matthias Krüger-0/+4
add feature flag for `type_changing_struct_update` This implements the PR0 part of the mentoring notes within #86618. overrides the previous inactive #86646 pr. r? ```@nikomatsakis```
2021-10-22add feature flag for `type_changing_struct_update`Charles Lew-0/+4
2021-10-14Revert "Stabilize `arbitrary_enum_discriminant`"Mark Rousskov-0/+3
This reverts commit 7a62f29f3171767090949778ce0f161e930706b9.
2021-10-08Add feature gate to non_exhaustive_omitted_patterns lintDevin Ragotzy-0/+3
Actually add the feature to the lints ui test Add tracking issue to the feature declaration Rename feature gate to non_exhaustive_omitted_patterns_lint Add more omitted_patterns lint feature gate
2021-10-06Clean up code a bit:Guillaume Gomez-1/+1
* Remove "bool_to_options" feature * Update version for compiler feature * rustfmt
2021-10-05Add test case for `doc_cfg_hide` feature gateJoshua Nelson-3/+3
2021-10-05Allow adding a set of cfg's to hide from being implicitly doc(cfg)'dWim Looman-0/+3
By adding #![doc(cfg_hide(foobar))] to the crate attributes the cfg #[cfg(foobar)] (and _only_ that _exact_ cfg) will not be implicitly treated as a doc(cfg) to render a message in the documentation.
2021-10-04Stabilize `const_panic`Jacob Pratt-3/+0
2021-09-24Stabilize `feature(macro_attributes_in_derive_output)`Vadim Petrochenkov-3/+0
2021-09-22Support `#[track_caller]` on closures and generatorsAaron Hill-0/+2
This PR allows applying a `#[track_caller]` attribute to a closure/generator expression. The attribute as interpreted as applying to the compiler-generated implementation of the corresponding trait method (`FnOnce::call_once`, `FnMut::call_mut`, `Fn::call`, or `Generator::resume`). This feature does not have its own feature gate - however, it requires `#![feature(stmt_expr_attributes)]` in order to actually apply an attribute to a closure or generator. This is implemented in the same way as for functions - an extra location argument is appended to the end of the ABI. For closures, this argument is *not* part of the 'tupled' argument storing the parameters - the final closure argument for `#[track_caller]` closures is no longer a tuple. For direct (monomorphized) calls, the necessary support was already implemented - we just needeed to adjust some assertions around checking the ABI and argument count to take closures into account. For calls through a trait object, more work was needed. When creating a `ReifyShim`, we need to create a shim for the trait method (e.g. `FnOnce::call_mut`) - unlike normal functions, closures are never invoked directly, and always go through a trait method. Additional handling was needed for `InstanceDef::ClosureOnceShim`. In order to pass location information throgh a direct (monomorphized) call to `FnOnce::call_once` on an `FnMut` closure, we need to make `ClosureOnceShim` aware of `#[tracked_caller]`. A new field `track_caller` is added to `ClosureOnceShim` - this is used by `InstanceDef::requires_caller` location, allowing codegen to pass through the extra location argument. Since `ClosureOnceShim.track_caller` is only used by codegen, we end up generating two identical MIR shims - one for `track_caller == true`, and one for `track_caller == false`. However, these two shims are used by the entire crate (i.e. it's two shims total, not two shims per unique closure), so this shouldn't a big deal.
2021-09-22Auto merge of #88865 - guswynn:must_not_suspend, r=oli-obkbors-0/+4
Implement `#[must_not_suspend]` implements #83310 Some notes on the impl: 1. The code that searches for the attribute on the ADT is basically copied from the `must_use` lint. It's not shared, as the logic did diverge 2. The RFC does specify that the attribute can be placed on fn's (and fn-like objects), like `must_use`. I think this is a direct copy from the `must_use` reference definition. This implementation does NOT support this, as I felt that ADT's (+ `impl Trait` + `dyn Trait`) cover the usecase's people actually want on the RFC, and adding an imp for the fn call case would be significantly harder. The `must_use` impl can do a single check at fn call stmt time, but `must_not_suspend` would need to answer the question: "for some value X with type T, find any fn call that COULD have produced this value". That would require significant changes to `generator_interior.rs`, and I would need mentorship on that. `@eholk` and I are discussing it. 3. `@estebank` do you know a way I can make the user-provided `reason` note pop out? right now it seems quite hidden Also, I am not sure if we should run perf on this r? `@nikomatsakis`