about summary refs log tree commit diff
path: root/src/test/ui/stability-attribute
AgeCommit message (Collapse)AuthorLines
2022-02-24don't special case `DefKind::Ctor` in encodinglcnr-8/+8
2022-02-03Add missing const stability attributesJacob Pratt-7/+9
2022-02-03Require const stability on all stable const itemsJacob Pratt-9/+27
This was supposed to be the case previously, but a missed method call meant that trait impls were not checked.
2022-01-12Bless tests.Camille GILLOT-105/+129
2021-11-23Rollup merge of #90856 - ↵Matthias Krüger-0/+58
ken-matsui:suggestion-to-wrap-vec-allocator-api-in-tuple, r=davidtwco Suggestion to wrap inner types using 'allocator_api' in tuple This PR provides a suggestion to wrap the inner types in tuple when being along with 'allocator_api'. Closes https://github.com/rust-lang/rust/issues/83250 ```rust fn main() { let _vec: Vec<u8, _> = vec![]; //~ ERROR use of unstable library feature 'allocator_api' } ``` ```diff error[E0658]: use of unstable library feature 'allocator_api' --> $DIR/suggest-vec-allocator-api.rs:2:23 | LL | let _vec: Vec<u8, _> = vec![]; - | ^ + | ----^ + | | + | help: consider wrapping the inner types in tuple: `(u8, _)` | = note: see issue #32838 <https://github.com/rust-lang/rust/issues/32838> for more information = help: add `#![feature(allocator_api)]` to the crate attributes to enable ```
2021-11-24Suggestion to wrap inner types using `allocator_api` in tupleKen Matsui-0/+58
2021-11-18Move some tests to more reasonable directoriesCaio-0/+19
2021-11-08Don't abort compilation after giving a lint errorJoshua Nelson-11/+24
The only reason to use `abort_if_errors` is when the program is so broken that either: 1. later passes get confused and ICE 2. any diagnostics from later passes would be noise This is never the case for lints, because the compiler has to be able to deal with `allow`-ed lints. So it can continue to lint and compile even if there are lint errors.
2021-07-26Add long explanation for E0544.Chris Midgley-1/+1
2021-06-15Use last segmenthi-rustin-18/+18
2021-06-15shrinking the deprecated method spanhi-rustin-8/+8
2021-06-04Revert "shrinking the deprecated method span"Rich Kadel-8/+8
2021-05-24shrinking the deprecated method spanhi-rustin-8/+8
2021-05-09remove const_fn feature gateRalf Jung-1/+1
2021-04-03Remove redundant `ignore-tidy-linelength` annotationsSimon Jakobi-74/+72
This is step 2 towards fixing #77548. In the codegen and codegen-units test suites, the `//` comment markers were kept in order not to affect any source locations. This is because these tests cannot be automatically `--bless`ed.
2021-03-15More precise spans for HIR pathsVadim Petrochenkov-4/+4
2021-03-05Auto merge of #71481 - estebank:inherit-stability, r=nikomatsakisbors-21/+23
Inherit `#[stable(..)]` annotations in enum variants and fields from its item Lint changes for #65515. The stdlib will have to be updated once this lands in beta and that version is promoted in master.
2021-02-18Add long explanation for E0549Jesus Rubio-1/+1
2021-02-17Add long explanation for E0543Jesus Rubio-1/+1
2021-02-15Add long explanation for E0545Jesus Rubio-1/+1
2021-02-10Tweak stability attribute diagnostic outputEsteban Küber-8/+14
2021-02-10Inherit `#[stable(..)]` annotations in enum variants and fields from its itemEsteban Küber-17/+13
2021-02-08Add long explanation for E0547Jesus Rubio-1/+1
2021-02-06Add long error explanation for E0542Jesus Rubio-1/+1
2021-01-15Don't mark `ineffective_unstable_trait_impl` as an internal lintJoshua Nelson-2/+2
It's not an internal lint: - It's not in the rustc::internal lint group - It's on unconditionally, because it actually lints `staged_api`, not the compiler This fixes a bug where `#[deny(rustc::internal)]` would warn that `rustc::internal` was an unknown lint.
2020-12-16Allow `since="TBD"` for rustc_deprecatedbstrie-4/+14
2020-12-07Move some tests to subdirectoriesVadim Petrochenkov-0/+234
2020-12-02bless stability-attribute-sanity ui testDaiki Ihara-1/+1
2020-11-02Improve deprecation attribute diagnostic messages.Mara Bos-6/+2
(From the PR feedback.) Co-authored-by: Esteban Küber <esteban@kuber.com.ar>
2020-11-01Use the right span for errors about #[deprecated] attributes.Mara Bos-9/+15
2020-09-27Rollup merge of #77203 - ecstatic-morse:const-stability-attr-checks, r=oli-obkJonas Schievink-0/+20
Check for missing const-stability attributes in `rustc_passes` Currently, this happens as a side effect of `is_min_const_fn`, which is non-obvious. Also adds a test for this case, since we didn't seem to have one before.
2020-09-25Test for missing const-stability attributesDylan MacKenzie-0/+20
2020-09-23Add enum and type alias tests for generic default stabilityJacob Hughes-2/+540
2020-09-22Fix compilation & test failuresJacob Hughes-32/+32
2020-09-22Test removing unstable default parameterAvi Dessauer-0/+14
2020-09-22Test unstable Alloc param on BoxAvi Dessauer-2/+50
2020-09-22Add unstable default feature enabled testAvi Dessauer-28/+38
2020-09-22Add test case demonstrating leakAvi Dessauer-22/+24
2020-09-22Test stability on default parameter of deprecatedAvi Dessauer-1/+170
2020-09-22Add more testsAvi Dessauer-1/+73
2020-09-22Fix testsAvi Dessauer-6/+6
2020-09-22Unstable default types leak in public fieldsAvi Dessauer-7/+11
2020-09-22Comment out broken testsAvi Dessauer-9/+33
2020-09-22Uncomment struct testsAvi Dessauer-27/+27
2020-09-22ignore-tidy-linelength generic default stab testAvi Dessauer-0/+1
Co-authored-by: Tim Diekmann <21277928+TimDiekmann@users.noreply.github.com>
2020-09-22Stability annotations on generic trait parametersAvi Dessauer-0/+127
2020-09-11Improve `ineffective_unstable_trait_impl` error message.Mara Bos-2/+3
2020-09-11Add test for unstable trait impl lint.Mara Bos-0/+38
2020-07-20Parse rustc_deprecated as deprecated attributeMark Rousskov-3/+3
2020-05-02Add long error explanation for E0539unexge-1/+2